Results 1 to 2 of 2

Thread: How to get a post?

  1. #1

    Thread Starter
    Member mylene_vbasic6's Avatar
    Join Date
    Jan 2002
    Posts
    61

    How to get a post?

    while running a jsp, I need it to return a POST, but it seems that it always return a GET.

    This could be proof by adding this statement 'getMethod()=<%=request.getMethod()%' and the result is GET.

    how could I get a POST?

    Thanks

    heres the sample code
    <TABLE>
    <TR>
    <TD>JDBC Driver:</TD>
    <TD><input type="text" name="driver" value="com.ddtek.jdbc.sqlserver.SQLServerDriver" size="60" > </input>
    </TD>
    </TR>
    <TR>
    <TD>JDBC URL:</TD>
    <TD><input type="text" name="url" value="jdbc:datadirect:sqlserver://RICHARD;PortNumber=1433;DatabaseName=EBIS" size="60" > </input>
    </TD>
    </TR>
    <TR>
    <TD>User Name:</TD>
    <TD><input type="text" name="user" value="EWSYS" size="35" > </input></TD>
    </TR>
    <TR>
    <TD>User Password:</TD>
    <TD><input type="password" name="password" value="EWSYS" size="20" maxlength="20" ></input></TD>
    </TR>
    <tr><td>getMethod()=<%=request.getMethod()%></td></tr>
    </TABLE></CENTER>
    Birds with the same feather, are the same birds.

  2. #2
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    It's a POST only if the page was reached by submitting a form that has POST as method.
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width