By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,473 Members | 3,504 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,473 IT Pros & Developers. It's quick & easy.

Anchor Tag in default.asp causes page to reload???

P: n/a
I have a home page on an intranet called default.asp I just type in
the server name to take me to the default page http://server. The home
page has an anchor name tag: <A name="fred">Freds Info</A>

It is located by this anchor href tag: <A href="#fred">Up to Freds
Info</A>

The problem is that when I first use the link to take me up to Freds
Info, the default.asp page is reloaded then I am taken to the Freds
Info, which is a pain I dont want this to happen. I just want to click
the link and be taken to the part on the page.

After the page is reloaded I can then use the link again to go up to
Freds Info without the page reloading. What is the problem? Any help
would be appreciated. I am using IIS 4.0 on Windows NT.
Dominic
Jul 19 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
Have you accessed the file using //server/ or //server/default.asp? Can you
put a copy of the page up somewhere, so we can try to reproduce, rather than
guess what is really happening?


"Dominic" <lo************@hotmail.com> wrote in message
news:fb**************************@posting.google.c om...
I have a home page on an intranet called default.asp I just type in
the server name to take me to the default page http://server. The home
page has an anchor name tag: <A name="fred">Freds Info</A>

It is located by this anchor href tag: <A href="#fred">Up to Freds
Info</A>

The problem is that when I first use the link to take me up to Freds
Info, the default.asp page is reloaded then I am taken to the Freds
Info, which is a pain I dont want this to happen. I just want to click
the link and be taken to the part on the page.

After the page is reloaded I can then use the link again to go up to
Freds Info without the page reloading. What is the problem? Any help
would be appreciated. I am using IIS 4.0 on Windows NT.
Dominic

Jul 19 '05 #2

P: n/a
Dominic wrote on 12 nov 2003 in microsoft.public.inetserver.asp.general:
I have a home page on an intranet called default.asp I just type in
the server name to take me to the default page http://server. The home
page has an anchor name tag: <A name="fred">Freds Info</A>

It is located by this anchor href tag: <A href="#fred">Up to Freds
Info</A>


1 This has nothing to do with ASP, so please follow up on a clientside NG.

2 Cashe reloading is standard behavour of accessing an anchor, intra or
internet. An eventual server reload is possibly caused by an non-cashe
command. If you just want to scroll use clientside javascript scrollTo() in
an onclick.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 19 '05 #3

P: n/a
Hello Evertjan and Aaron thanks for your replys.

This is what I see in the message window of IE5.0 when I hover over
the link.

http://Server/#fred

I think it should be http://Server#fred

Seeing that I have the default document already in the temporary
internet file folder as http://Server it should not have to ask the
server for a new page.

However I do have Cache:Control no-cache as a header in IIS4.0 so that
documents loaded to the browser from the default page links are not
cached.

The Html for the anchor tags is the same as previously posted.

I am not sure of the scrollTo()?? or how it works and what does NG
mean?

Thanks people.
Dominic


1 This has nothing to do with ASP, so please follow up on a clientside NG.

2 Cashe reloading is standard behavour of accessing an anchor, intra or
internet. An eventual server reload is possibly caused by an non-cashe
command. If you just want to scroll use clientside javascript scrollTo() in
an onclick.

Jul 19 '05 #4

P: n/a
Dominic wrote on 13 nov 2003 in microsoft.public.inetserver.asp.general:
This is what I see in the message window of IE5.0 when I hover over
the link.
In the status bar, I preaume.
http://Server/#fred

I think it should be http://Server#fred
No, no,

http://Server and http://Server/ are short for http://Server/index.asp
[if your IIS defaults to index.asp, that is].

http://Server/#fred means http://Server/index.asp#fred

http://Server#fred is illogical and probably would not work, because
Server is not a file but the virtual root directory. You can try it in
your browser and wil see the browser replaces that immediately by adding
the slash. [IE6 tested]
Seeing that I have the default document already in the temporary
internet file folder as http://Server it should not have to ask the
server for a new page.

However I do have Cache:Control no-cache as a header in IIS4.0 so that
documents loaded to the browser from the default page links are not
cached.
It does not influence the links, just the pages themselves.

So every http://Server/index.asp#fred will reload from the server, as
promised.

Why not remove the no-cache if you hate it for this page.
[..]
I am not sure of the scrollTo()?? or how it works and what does NG
mean?


scrollTo() is clientside Javascript [you were in fact asking for a
clientside solution] and NG is [this] NewsGroup

[please do not bottom quote on usenet, but top/interquote sparingly]

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 19 '05 #5

P: n/a
> http://Server/#fred

I think it should be http://Server#fred


No, #bookmarks apply to a *page* not a server.
Jul 19 '05 #6

P: n/a
Thanks again Aaron and Evertjan,
You have been both helpful :-)
I can understand now Evertjan about what you have been showing me and
I guess because I have the no-cache turned on that this is the main
problem, not the asp and not the html. I will turn it off and see how
I go. Thanks for all the other bits you have identified such as the
'status bar' and the http:server/ etc.
Aaron thanks for your help.
I'll be back with good news I hope.
cheers
Dominic
Jul 19 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.