aspose file tools*
The moose likes JSP and the fly likes Help Clean up This Code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Help Clean up This Code" Watch "Help Clean up This Code" New topic
Author

Help Clean up This Code

Garrett Smith
Ranch Hand

Joined: Jun 27, 2002
Posts: 401
The code is working fine but is there a cleaner strategy using tag files that is simple(r)?

The idea is to make a quiz where the form submits to the same page and displays the results, allowing the user to try again until he gets the right answer. This is a one-off, but I still like to keep the jsp clean anyway.




comp.lang.javascript FAQ: http://jibbering.com/faq/
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Simpler? No. Cleaner? Substantially, depending on how far you want to go--don't even need custom tags, just pay attention to what you're doing:It's the same philosophy as refactoring Java: find yourself repeating yourself yourself? Eliminate duplication and obfuscation.(Notice also that using a label tag around something that isn't a label is silly.)Meh--diminishing returns. If you're going to go this far, just use JSP templates.
Mukhi Vla
Ranch Hand

Joined: Apr 22, 2010
Posts: 50
Meh--diminishing returns. If you're going to go this far, just use JSP templates.


What is jsp template? I am asking this question because i want to implement mail client program using spring and jsp. I thinking of having a jsp template that have mail template in it. But i have no idea how to create a jsp template....

Thanks
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

c:import/c:params
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Help Clean up This Code