Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and 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 ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Is there an automated tool that converts HTML to JSP?

 
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all, I'm looking for a tool to automate the HTML to JSP conversion. I have a huge number of HTML containing flash tags which needs to be converted to JSP.
 
Marshal
Posts: 67425
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rename the files from .html to .jsp. Now they are JSP files. Beyond that, what are you looking for?
 
John Bennet
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Automated way to add tags such as <% or %>
 
Ranch Hand
Posts: 502
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But, why do you want to add the <% %> tags. Wont the HTML page work as it is? or do you want your HTML content to be generated from a backend database?
 
Bear Bibeault
Marshal
Posts: 67425
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That makes no sense. What would one put into such "tags"?
 
John Bennet
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, exactly! I want your HTML content to be generated from a backend database
 
Bear Bibeault
Marshal
Posts: 67425
173
Mac Mac OS X IntelliJ IDE jQuery Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Repeat: how would any automated tool know how to go about replacing random HTML text with database access tags?

The bad news: you're really going to have to dig in and do it by hand.

The good news: it's not that hard.

Step 1: Write backend code (not in a JSP) that obtains the values you want to display.

Step 2: In a servlet controller, call this code to get the data and place it on the request as scoped variable(s).

Step 3: On the JSP page use JSP technology (preferably the JSTL) to display the values.
[ November 23, 2004: Message edited by: Bear Bibeault ]
 
Jayesh Lalwani
Ranch Hand
Posts: 502
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[Potentially problematic response removed.]
[ November 23, 2004: Message edited by: Bear Bibeault ]
 
Ranch Hand
Posts: 150
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
[Potentially problematic response removed.]
[ November 23, 2004: Message edited by: Bear Bibeault ]
 
Every plan is a little cooler if you have a blimp. And a tiny ad.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic