:) Thanks!
2012/7/19 Thiago H de Paula Figueiredo
> On Thu, 19 Jul 2012 11:50:57 -0300, arterzatij
> wrote:
>
> Hi Thiago, how do you get the file from db?
>> I mean the BLOB type of data base to a Java Type?
>>
>
> Yep, probably to a byte array.
>
> --
> Thiago H. de Paula Figueiredo
>
>
> --
On Thu, 19 Jul 2012 11:50:57 -0300, arterzatij
wrote:
Hi Thiago, how do you get the file from db?
I mean the BLOB type of data base to a Java Type?
Yep, probably to a byte array.
--
Thiago H. de Paula Figueiredo
-
To unsu
Hi Thiago, how do you get the file from db?
I mean the BLOB type of data base to a Java Type?
Thanks in advance!
--
View this message in context:
http://tapestry.1045711.n5.nabble.com/Uploading-then-displaying-Images-tp3423946p5714604.html
Sent from the Tapestry - User mailing list archive at
Ah, good to hear!
On Mon, Aug 8, 2011 at 5:52 AM, David Canteros
wrote:
> Hi again Josh, i had not seen your first response, there was the solution to
> my problem.
> Thank you!
> David
>
>
>
> --
> David Germán Canteros
>
>
> 2011/
Hi again Josh, i had not seen your first response, there was the solution to
my problem.
Thank you!
David
--
David Germán Canteros
2011/8/6 David Canteros
> Yes, user is an object loaded in the setupRender() method, and getImag
Yes, user is an object loaded in the setupRender() method, and getImage()
returns an InputStream every time the page is loaded.
--
David Germán Canteros
2011/8/5 Josh Canfield
> The real issue is more likely the first point, you'
The real issue is more likely the first point, you're getting your
InputStream from an object from the session. Does calling getImage()
return a new InputStream every time?
On Fri, Aug 5, 2011 at 2:44 PM, David Canteros
wrote:
> Hi Josh;
> I have already tried with PageRenderLinkSource
Hi Josh;
I have already tried with PageRenderLinkSource but It has the
same behavior. I did not know the difference between LinkSource and
PageRenderLinkSource, thanks for the information!
David
--
David Germán Canteros
Also.
> private LinkSource linkSource;
This is an internal class, you should be using PageRenderLinkSource.
You can replace:
> linkSource.createPageRenderLink(DisplayImagePage.class.getSimpleName(),
> false, new Object[]{imageId});
with
pageRenderLinkSource.createPageRenderLinkWithContext(D
> public InputStream *getStream*() throws IOException {
> User user =
> (User)_request.getSession(true).getAttribute("user");
> return user.getImage();
> }
It looks like you're pulling the User object from the session and then
getting the InputSt
Hi
I have to show a image loaded from database BLOB field. I implemented
Thiago's suggestion, I have created a page with the following code:
public class ShowImagePage {
@Inject
private LinkSource linkSource;
(...)
public Link *getUploadedFile*(String imageId) {
retu
Thanks everyone for the responses so far, conceptually I think this is
coming together for me.
So, I'm glad the context path was not a good idea, it felt dirty from
the beginning. Avoiding that, there are two main options: use the
database to store/retrieve the images, or use a configured syst
On Fri, 11 Mar 2011 09:24:35 -0300, LLTYK wrote:
Nobody's mentioned createEventLink. That's where you get the image url,
create an event link pointing to the event handler that returns the
stream response.
I haven't mentioned it because my preferred approach is to create a page
just for r
Nobody's mentioned createEventLink. That's where you get the image url,
create an event link pointing to the event handler that returns the stream
response.
--
View this message in context:
http://tapestry-users.832.n2.nabble.com/Uploading-then-displaying-Images-tp6159049p6161239.html
Sent from t
On Thu, Mar 10, 2011 at 5:02 PM, Josh Canfield wrote:
>> Sorry, but that's a really bad advice - never put uploaded files under
>> the context path of your application. What happens when you update the
>> WAR?
> Strongly agree.
>> return new
>> BufferedImageStreamResponse(ImageIO.r
On Thu, 10 Mar 2011 22:02:04 -0300, Josh Canfield
wrote:
Sorry, but that's a really bad advice - never put uploaded files under
the context path of your application. What happens when you update the
WAR?
Strongly agree.
I agree too. I put my uploaded files in the database. I was just tryi
> Sorry, but that's a really bad advice - never put uploaded files under
> the context path of your application. What happens when you update the
> WAR?
Strongly agree.
> return new
> BufferedImageStreamResponse(ImageIO.read(imageStorage.getImageInputStream(imageId)));
What is th
On Thu, Mar 10, 2011 at 4:11 PM, Thiago H. de Paula Figueiredo
wrote:
> On Thu, 10 Mar 2011 19:24:52 -0300, Rich M wrote:
>> Primarily because I can't think of a reasonable way to build a URL to the
> I think you have a confusion here. The folder structure you use while
> developer doesn't matter
On Thu, 10 Mar 2011 19:24:52 -0300, Rich M wrote:
Primarily because I can't think of a reasonable way to build a URL to
the file that could actually be served. I wish I was more knowledgeable
about servlets and such, but if my application is running from a WAR,
how would I get any files in
I think this thread has gotten me very confused.
You have uploaded files, presumably you know where they are and can
identify them. You want to get those files to display in your browser.
In order to do that you create an tag that contains a
URL as the value of the src attribute that points to yo
On 03/10/2011 04:21 PM, Thiago H. de Paula Figueiredo wrote:
On Thu, 10 Mar 2011 17:49:14 -0300, Rich M wrote:
Okay, that makes sense. Is there a way to use the StreamResponse
instead of the URL then to display an image in the browser?
Unless you want to generate one of that data URLs
(http
On Thu, 10 Mar 2011 17:49:14 -0300, Rich M wrote:
Okay, that makes sense. Is there a way to use the StreamResponse instead
of the URL then to display an image in the browser?
Unless you want to generate one of that data URLs
(http://en.wikipedia.org/wiki/Data_URI_scheme), you'll need to ge
On 03/10/2011 03:17 PM, Thiago H. de Paula Figueiredo wrote:
On Thu, 10 Mar 2011 16:37:29 -0300, Rich M wrote:
Hi,
Hi!
I had read this thread
http://tapestry.1045711.n5.nabble.com/How-to-display-Blob-byte-array-image-td2436148.html
along with other information regarding uploading/displayi
On Thu, 10 Mar 2011 16:37:29 -0300, Rich M wrote:
Hi,
Hi!
I had read this thread
http://tapestry.1045711.n5.nabble.com/How-to-display-Blob-byte-array-image-td2436148.html
along with other information regarding uploading/displaying images. I
think I'm a bit confused as to what my ImageS
24 matches
Mail list logo