HTML JSP HREF parameters

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Babak

    HTML JSP HREF parameters

    Most likely a dumb question, but I am week in this area.
    I have a table which is generated dynamically in my jsp as I do a jdbc
    query. I have created an anchor
    <TD><A><HREF="< %bean.getValue( )%>?id=rs.getID ()%>...I believe the
    value is posted, since I move my mouse on top of the field and it
    displays the right value....but where? I need to know which API I
    should use to read id (HTTPServletReq uest.getxxx?)
    Thank you very much.
  • Jim Dabell

    #2
    Re: HTML JSP HREF parameters

    Babak wrote:
    [color=blue]
    > I have a table which is generated dynamically in my jsp as I do a jdbc
    > query. I have created an anchor
    > <TD><A><HREF="< %bean.getValue( )%>?id=rs.getID ()%>...I believe the
    > value is posted, since I move my mouse on top of the field and it
    > displays the right value....but where? I need to know which API I
    > should use to read id (HTTPServletReq uest.getxxx?)[/color]

    This newsgroup isn't the best place to ask about server-side programming
    (it's for HTML, hence the name ciwa.html). In future, please try and find
    a suitable newsgroup, you are likely to get much better, faster help.

    From the little I know about JSP, it looks like you want the getParameter()
    method. Handling query strings is just about as basic as you can get with
    server-side scripting, I'm sure you can find the answer in any decent
    tutorial.

    The HTML you have posted is badly broken, as any validator would tell you:

    <URL:http://validator.w3.or g/>

    Also, remember that the JSP code goes between <% and %>, and that everything
    outside of that is plain HTML that will be parsed by the user-agent and not
    the server.

    --
    Jim Dabell

    Comment

    Working...