Loading page and staring half way down

Discussion in 'Javascript' started by Kerrin, Sep 26, 2004.

  1. Kerrin

    Kerrin Guest

    I'm trying to go to a new page, but I want it to jump straight to a
    specific part of the page instead of starting at the top of the page.

    Anyone got any idea on how this is done?

    I was trying to get it to work with a <a name="here"> tag, but the
    browser ignores the #here on the end of my cgi script name.

    I tried using javascript and the onload event to rewrite the url, but
    I couldn't get that to work either.

    Is it possible to go to a web page and have it start half way down, or
    can you only do this on the same page?

    Kerrin
     
    Kerrin, Sep 26, 2004
    #1
    1. Advertising

  2. Kerrin

    Kerrin Guest

    Sorry, I don't think I was clear about the issue I was having.

    The problem is I have a page that links to another page, except I want
    it to open the page half way down, and I want to call a cgi script to
    get there.
    There are multiple pages, and they cross reference each other. Because
    of this I want to use a single form to do all the cross referencing,
    so the destination and tag name are dynamic.
    I was using javascript to modify the form action to append the
    #<name>, but IE won't allow me to do this (NetScape was fine and
    worked as I wanted).

    So now I need the load the page, and then after the page has loaded,
    move the page down to the selected section. So when the page loads the
    #<name> is not there, and I simply wish to use the onload event to
    move the page.

    So all I need to know is how do you make javascript move the page to
    the <a name="blah"> tag?

    Kerrin

    Andrew Thompson <> wrote in message news:<13s6vzlj946rt.1dvr32dfuam08$>...
    > On 26 Sep 2004 05:32:54 -0700, Kerrin wrote:
    >
    > I am not sure I understand you correctly, but..
    >
    > > Is it possible to go to a web page and have it start half way down, or
    > > can you only do this on the same page?

    >
    > Sure, this should start you part way down the JS FAQ
    > <http://www.jibbering.com/faq/#FAQ4_32>
    > > I was trying to get it to work with a <a name="here"> tag, but the
    > > browser ignores the #here on the end of my cgi script name.

    >
    > There must be somthing wrong with your
    > a) HTML (or the HTML your CGI script is writing)
    > b) CGI script
    > c) Browser
    >
    > I would put my money on a) or b), and my first suggestion is
    > to produce a static HTML page that you have validated* and
    > can link to an anchor before you proceed.
    >
    > * <http://validator.w3.org/>
    >
    > HTH
     
    Kerrin, Sep 27, 2004
    #2
    1. Advertising

  3. Kerrin

    Kerrin Guest

    > Posting replese on top does not assist clarity
    I was trying to rephrase the entire question and thought it would be
    clearer all thogether at the top, instead of spread out in the post
    for the sake of it.
    As for putting it at the top, I'm sorry, I haven't been a regular
    poster in years and thought it was the correct place to put it. Now
    you have so politely slapped my wrists I'll be good. And I didn't even
    moan about the fact you clearly didn't proof read you post before
    posting it (as you can see in the above quote). Oh whoops, I guess I
    did.

    > Kerrin, please post comments below and trim..

    Yes, I should have trimmed, we can't all be prefect all the time.

    > This all sounds like a very confusing navigation
    > system Kerrin, are you sure it is a good idea, rather
    > than 'heck, we have the technology'?


    Yes, I have got a little carried away with the original idea I had for
    this area of the site.

    > This will fail for any browser with JS disabled.


    Well considering that you have no idea what the site is, you have made
    an assumption that the site is conventional, which it isn't. I'm
    afraid the site that this is for requires JS (it wouldn't be possible
    otherwise), so I saw no harm in using it on the area of the site.

    > d) your basic design
    > I was wrong, it is seeming like it is d).


    I never saw the point of flaming people, why can't people be polite? I
    just wanted to know the answer to a question, and I am greatful of
    your help.

    > Make the site function with JS disabled first, then
    > improve it with DHTML.


    I was intending on rethinking this area of the site, but the site as a
    whole will require JS.

    Kerrin
     
    Kerrin, Sep 27, 2004
    #3
  4. Kerrin

    Kerrin Guest

    Andrew Thompson <> wrote in message news:<m6e3hujrv61d.q6ri8fj4wda9$>...
    > On 27 Sep 2004 14:21:59 -0700, Kerrin wrote:


    > Pointing them towards a page explaining (with screen shots)
    > - the wonderful tools you are creating for their benefit
    > - the technology (JS) upon which it is based
    > - the way to enable JS in a variety of browsers**.
    >
    > ** This is more important than you might think, as
    > most web-surfers would not know how to do it.


    That is a good point, and one I intend to use.

    > > I never saw the point of flaming people, why can't people be polite?

    >
    > (chuckles) That was not a flame, your
    > ass ain't even smokin'! ;-)


    Well, I found it a little warm for my liking.

    > But of course, I am making further assumptions (you want
    > it indexed on Google). Perhaps we might cirvumvent too
    > many more guesses with an URL.


    Yes I will be submitting the site to search engines when it is ready,
    but I still have to do that. I am only now writting the manual (which
    is the section my question was for.)

    > Where's your site?


    http://kerrin.zapto.org

    The site is far from finished. There is plenty wrong with it, that I
    intend to fix.

    Kerrin
     
    Kerrin, Sep 28, 2004
    #4
  5. Kerrin

    Kerrin Guest

    > 1) I have no problem seeing the text on the left, but
    > some will. If your users are not guaranteed better than
    > 18/18 vision, you might think about increasing the contrast,
    > which you might do by making the text white, or light gray.


    I will be getting new graphics (again) for the site this evening, I'm
    not a graphics person, so I'm just putting in what ever I get and
    giving feed back on changes. (You should have seen the previous
    version! Green text on a blue background!)

    > 2) <http://kerrin.zapto.org/cgi/page.cgi>
    > In the select for screen size..
    > a) Some users will be 'not listed' in the list of 4 you
    > provide


    The list there is for testing only, to be honest I don't like that,
    and have plans on doing it automatically.

    > 3) Just what is that screensize select for? It is unnecessary
    > for the pages you already have, so I guess it is for functionality
    > that happens after registering, is that right?


    It's used to calculate how much board can be shown to the user. Don't
    feel scared about registering, the site doesn't bite. With out
    registering you have seen 1% of the sites functionality (and a very
    dull bit at that).

    > 4) Get in touch with your inner validator (very Zen, huhh?)


    I will, at a later time.

    Kerrin
     
    Kerrin, Sep 30, 2004
    #5
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. trint
    Replies:
    4
    Views:
    717
    =?ISO-8859-1?Q?G=F6ran_Andersson?=
    Sep 11, 2007
  2. Iain Barnett
    Replies:
    10
    Views:
    229
    Brian Candler
    Aug 18, 2010
  3. joe chesak
    Replies:
    7
    Views:
    294
    (r.*n){2}
    Sep 23, 2010
  4. Jerry Preston

    Firefox broswer staring Perl CGI

    Jerry Preston, Nov 8, 2004, in forum: Perl Misc
    Replies:
    8
    Views:
    238
    Vetle Roeim
    Nov 10, 2004
  5. Mike Ballard
    Replies:
    6
    Views:
    275
    Dr.Ruud
    Nov 15, 2005
Loading...

Share This Page