SitePoint Sponsor

User Tag List

Results 1 to 8 of 8
  1. #1
    SitePoint Evangelist
    Join Date
    Nov 2003
    Location
    Brisbane, Australia
    Posts
    408
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Going to location on page after refresh

    Hi All

    I have a very long admin page and cannot make it shorter. There is a part near the bottom of the page that you can update. If you do anything you go to another page to do it then you are redirected back to the main page.

    When this happens you go back to the top of the page and have to scroll down to the bottom, which is getting very annoying.

    I have tried using #bottom but that did not work.

    Here is an example:

    At the bottom of the main page you click delete...
    It goes to the page that has the delete code in it then redirects back to the main page but to the top.

    I donít want to go to the top I want to go to the bottom.

    I hope this makes sense.

    Any help would be great.

    Thanks

    mrmbarnes

  2. #2
    SitePoint Evangelist
    Join Date
    Jun 2005
    Posts
    436
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Open the admin file. Put this code where you want the page scrolled to.
    Code:
    <A NAME="bottom"> </A>
    Open the page that deletes it. Edit the URL it redirects to so it goes to:
    file.php#bottom

    Hope this helps.

    e39m5

  3. #3
    SitePoint Evangelist
    Join Date
    Nov 2003
    Location
    Brisbane, Australia
    Posts
    408
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi

    Thanks for that but it does not work.

    Any other ideas?

    Thanks

  4. #4
    SitePoint Addict silentcollision's Avatar
    Join Date
    Jun 2006
    Location
    New Zealand
    Posts
    388
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Uh, that will work, maybe you put it in wrong? Can we see the code?

  5. #5
    SitePoint Evangelist
    Join Date
    Nov 2003
    Location
    Brisbane, Australia
    Posts
    408
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi

    Here's the redirect:

    content-management.php?pageid=contentmanagement&contentpageid=$contentpageid#bottom

    and here's the link on the main page:

    <a name='bottom'> </a>

    Thanks

  6. #6
    SitePoint Zealot
    Join Date
    Jan 2007
    Location
    Australia
    Posts
    137
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Try <a href="#" id="bottom"></a> and send the user to #bottom.

  7. #7
    SitePoint Evangelist
    Join Date
    Nov 2003
    Location
    Brisbane, Australia
    Posts
    408
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Still no joy?????

  8. #8
    SitePoint Evangelist catweasel's Avatar
    Join Date
    Apr 2007
    Location
    Goldfields, VIC, Australia
    Posts
    518
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by mrmbarnes View Post
    Still no joy?????
    replace this line -
    content-management.php?pageid=contentmanagement&contentpageid=$contentpageid#bottom

    with this -
    content-management.php#bottom?pageid=contentmanagement&contentpageid=$contentpageid

    If that doesn't work view the html source in your browser to check that the variable is actually printing out correctly.


Bookmarks

Posting Permissions

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