GeeCON Prague 2014*
The moose likes Other Application Frameworks and the fly likes How to send data through html anchor tag when it is clicked in Spring ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "How to send data through html anchor tag when it is clicked in Spring ?" Watch "How to send data through html anchor tag when it is clicked in Spring ?" New topic
Author

How to send data through html anchor tag when it is clicked in Spring ?

Ramesh kangamuthu
Ranch Hand

Joined: Mar 13, 2007
Posts: 79
Hi EveryBody,

How to send data through <a> tag when it is clicked in Spring ?


Thanks in Advance.


Best Regards,
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42023
    
  64
What exactly do you mean by "send data"? URLs can contain parameters, so that would be one way of including data. But that's a general feature of HTML/HTTP, and not Spring-specific.


Ping & DNS - my free Android networking tools app
Ramesh kangamuthu
Ranch Hand

Joined: Mar 13, 2007
Posts: 79
Hi Ulf,

Thank You. I want a request attribute value, like c:set var='var' value='value'/> should be sent through anchor tag without using javascript function when I click the tag. The problem is when I click the tag the form is not submitted, So attributes in request scope could not be sent to the URL.



Best Regards,

Ramesh K
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 42023
    
  64
Whatever you have in a request attribute value can most certainly be embedded in an <A HREF="..."> tag. URL parameters are the way to do that.

But I don't understand what an HREF has to do with an HTML form. Do you want to have a link that submits a form? If so, why not use a submit button?

Neither of these involves JavaScript.
 
GeeCON Prague 2014
 
subject: How to send data through html anchor tag when it is clicked in Spring ?