Win a copy of Svelte and Sapper in Action this week in the JavaScript 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 all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Printing value in jsp

Ranch Hand
Posts: 68
MySQL Database Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
where form is the object of DynaActionForm.
now i need to print the value in jsp page using javaScript
Posts: 9615
Mac OS X Linux Windows
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you can at all avoid it, do not use Struts 1. It is past end of life , unsupported, has not had an update in 6 years and has serious architectural issues.
That said, you will not be able to use JavaScript to directly write a variable in an Action to a JSP page because the Action runs on the server and the JavaScript runs in the web browser. You can, however, write the value somewhere on the page where JavaScript can use the value using a Struts tag (bean:write perhaps) and the JavaScript can do so when it is run in the browser.
    Bookmark Topic Watch Topic
  • New Topic