www.webdeveloper.com
Results 1 to 6 of 6

Thread: Jumping to anchor tags

  1. #1
    Join Date
    Jul 2003
    Posts
    6

    Arrow Jumping to anchor tags

    I am trying to submit some datails, but when the form is reloaded, it does not return to where it left off.

    I have set up some anchor tags, and have even hard coded the #30 to the end of the action=orderform.php so that it should jump to this line every time but it is not working.

  2. #2
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    What does orderform.php look like? Is it just a form processor that sends you somewhere else when it is done (ie. back to the form, etc)?

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

  3. #3
    Join Date
    Jul 2003
    Posts
    6
    orderform.php is the form itself, so it is just refreshing itself.

  4. #4
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    Can we see some code, please...

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

  5. #5
    Join Date
    Jul 2003
    Posts
    6
    OK. Here is the beginning and end of the code. The stuff in between is just replicas from 2 to 29.

    echo "<form name='addlines' action='orderform.php#30' method='post' target='addline'>
    <table width='65%' border='2'>
    <tr><td width='20'><b>No.</td><td width='230'>Part number</td><td width='80'>Qty</td><td>Description</td>
    </tr>
    <tr><td>1</td><td><input type='text' name='partno1' size='30' maxlength='20' value='$_POST[partno1]' onfocus='<a name=1>' onblur='document.addlines.submit()'>";
    $query1 = mysql_query ("SELECT * FROM parts WHERE partno like '$_POST[partno1]'");
    $row1 = mysql_fetch_row($query1);
    echo "</td>
    <td><input type='text' name='qty1' size='10' value='$_POST[qty1]'></td>
    <td>$row1[1]</td></tr>
    etc.
    etc.
    etc.
    <a name='30'><tr><td>30</td><td><input type='text' name='partno30' size='30' maxlength='20' value='$_POST[partno30]' onblur='document.addlines.submit()'>";
    $query30 = mysql_query ("SELECT * FROM parts WHERE partno like '$_POST[partno30]'");
    $row30 = mysql_fetch_row($query30);
    echo "</td>
    <td><input type='text' name='qty30' size='10' value='$_POST[qty30]'></td>
    <td>$row30[1]</td></tr>

  6. #6
    Join Date
    Dec 2002
    Location
    High on life
    Posts
    10,104
    This isn't going to work:

    onfocus='<a name=1>'

    try putting <a name=1> before the <input> tag...

    Personal website http://www.ryanbrill.com/
    Business website: http://www.infinitywebdesign.com/
    TypeSpace http://www.typespace.org/

    I reject your reality and substitute it with my own!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles