Win a copy of Rust Web Development this week in the Other Languages forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Jesse Silverman
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Piet Souris
  • Frits Walraven

calling an action through html:img tag

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi,
I have to display an image and some text in a page. The problem is that image is in form of byte array. To show this image as byte array i have changed the content type in jsp accordingly and this jsp is working fine. But since i have to display both image and text in the screen i need to create a jsp that will have an html:img tag which would call the action which in turn would invoke the jsp contaning logic of displaying byte array as image.
i tried this but the action mentioned in html:img tag is not being called. Can anyone please help me out why this is happening.
Thanks
 
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is an example of this in the struts-examples.war file that comes with the Struts download. Look at html-img.jsp and org.apache.struts.webapp.exercise.ImageAction. It looks like this example is doing pretty much what you're trying to do.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic