aspose file tools*
The moose likes Struts and the fly likes html:link : how to get only the URL ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "html:link : how to get only the URL ?" Watch "html:link : how to get only the URL ?" New topic
Author

html:link : how to get only the URL ?

Ken Rodriguez
Greenhorn

Joined: Oct 17, 2005
Posts: 3
How to get ONLY the URL generated by html:link tag in a JSP?
I do not want to supply the body inside <html:link> </html:link> tag pairs. Instead just the URL has to be generated and used somewhere--e.g. using for triggering on a button click. (or embed it somewhere else in HTML).

something like:

-----
function goBackThere()
{
document.href= '<html:link forward="thisFwdKeepsChanging" />';
}
..
..

<input type="button" value="Cancel" onClick goBackThere() >
------

This looks like pretty common task and i guess lot of people would have done it. Yet all my searches have turned up nothing for this .. Could someone please enlighten regd this or give pointers if it has been answered before ?

This is for **older** version of struts - before they split up the framework into 'Action Framework' and 'Shale framework'. The version we're using is 1.2.7

Thanks,
Ken
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: html:link : how to get only the URL ?