Auto Re-direct

  • Thread starter Thread starter John Parker
  • Start date Start date
J

John Parker

Is there a simple script I can add to my home page to automatically
(seamlessly) take the browser to another page..

For example my domain www.123.test

I want to automatically go to www.123.test/otherpage/


I am sure this is simple to do but I don't know how to..

Any assistance appreciated.

John Parker
 
Use a meta refresh tag between the head tags on the page.
<META HTTP-EQUIV=Refresh CONTENT="10; URL=otherpage.htm">

Will direct to otherpage.htm in 10 seconds.
Change 10 to the number of seconds you want.


--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed............
........................with a computer
 
The W3C offers recommendations, not standards, and the type of redirect to be used is really based
on the nature of the web site and it requirements.
--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
1. Not knowing the type of server the poster is using, the simplest answer
/ easiest solution for his is the meta refresh.

2. Yes I have. However the preferred method in the MSFT news groups is top
posting, as most of us who post here can remember what we read for the 1 or
2 seconds it takes to get to the next portion of the thread.

And yes I know about Quotefix.

Not sure about you, but I monitor over 25 news groups and I really don't
have time to scroll down.

--
Steve Easton
Microsoft MVP FrontPage
95isalive
This site is best viewed............
........................with a computer
 
As for "top posting", this is the preferred method in the FP newsgroup, with all prior content
retained, as many folks do not retain read messages. It is very helpful to know what prior solutions
have been offers and what has or has not work without have read all the way to bottom of the post to
see any prior replies.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
Hi Andreas,

I'd agree with not usng meta but a "proper http redirect" can only be done
from the server - maybe the user doesn't have that functionality available.
If they don't I'd use
<script type="text/javascript">
location.replace('otherpage.htm');
</script>
<noscript>
<META HTTP-EQUIV=Refresh CONTENT="0; URL=otherpage.htm">
</noscript>

As for your second point about posting style - top posting is very much
encouraged in this newsgroup and has been the norm here for as long as I can
remember (~5 years.) We tend to frown on people coming in here telling us to
how to run things, however "right" you feel you may be.

Jon
Microsoft MVP - FP
 
To add to what the others have said, what is "improper" about using the
refresh as was suggested?

Just because there is more than one solution doesn't make any of them
"wrong"...
 
I thank-you all for your very valuable feedback..

It is true I do not have direct server access and I am assuming most don't
either.. The refresh method works great for many of my needs but this one I
was looking for a seamless (no delay) redirect.. I think I have some good
info to work with and again I appreciate all your help.

John Parker
 
Well I took the time out to read the page Last Updated: Sunday, October 29,
2000 ....by any chance did you see this part:

"Therefore, we recommend that you use the "standard" quoting style described
here unless you have clear evidence that people in a particular newsgroup
actively prefer another style"

--
Joe

Forum Crafters:
http://www.forumcrafters.com
FrontPage Users Forums:
http://www.timeforweb.com/frontpage
 
seems that the reference really only dissuaded the meta refresh because it'd
"break" the back button. not so if there's a delay.

as for the top/ bottom posting.....when in Rome. I'll certainly remember,
should I venture into some snobby, totalitarian newsgroup, to post as you
desire.
 
John,

One thing that wasn't mentioned, if you do an instant auto-re-direct vs. a 7 to 10 second
auto-re-direct, and do not have a standard hyperlink, the search engines in many cases will not
index your website.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
no need for the delay in the meta refresh. if you know what type of server
side scripting you can use someone will give you a snippet in that language
that'll accomplish the same thing without the browser's involvement.

HTH
 
besides how often to you get re-directed then want to go back anyway? - go back to what?


| seems that the reference really only dissuaded the meta refresh because it'd
| "break" the back button. not so if there's a delay.
|
| as for the top/ bottom posting.....when in Rome. I'll certainly remember,
| should I venture into some snobby, totalitarian newsgroup, to post as you
| desire.
|
| --
| The email address on this posting is a "black hole". I got tired of all the
| spam.
| Please feel free to contact me here:
| http://nedp.net/contact/
| --
|
|
| | >
| > > Use a meta refresh tag between the head tags on the page.
| > > <META HTTP-EQUIV=Refresh CONTENT="10; URL=otherpage.htm">
| >
| > This is nonsense! Use a proper HTTP redirect:
| > <http://www.w3.org/QA/Tips/reback.html>
| >
| > BTW: Have you ever read
| > <http://www.xs4all.nl/~wijnands/nnq/nquote.html> ?
| >
| > --
| > Top-posting.
| > What's the most irritating thing on Usenet?
|
|
 
Hi

It's very simple, use JavaScript.

Here is an example:

Add this between <head> and </head>:

<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
redirTime = "10000";
redirURL = "http://www.123.test/otherpage/";
function redirTimer() { self.setTimeout
("self.location.href = redirURL;",redirTime); }
// End -->
</script>

and this one to your <body>

<body onLoad="redirTimer()">

Number 10000 is 10 seconds.


--Wizard--
 
What is the advantage of using this over the meta refresh?

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
None atall

Somebody made the valid point earlier in this thread that the downside of
using the meta is it breaks the back button - ie user goes to page meta
sends him to a different page he hits back the meta kicks in again and sends
him back to the same page. Endless loop. The javascript solution this guy
posted would do exactly the same.

The javascript I posted up earlier won't break the back button - the key is
location.replace('page.htm') rather than location.href='page.htm'. We'd
still need the meta as a fall back to cover non-script users
<script type="text/javascript">
location.replace('otherpage.htm');
</script>
<noscript>
<META HTTP-EQUIV=Refresh CONTENT="0; URL=otherpage.htm">
</noscript>

Jon
 
I know that I indicated the Meta Refresh, when I should have indicate the script you had posted.

However, if someone is re-directing from a soon to be expired domain or URL, then the need to use
the browser's back button is not a major issue.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 
That probably depends on the reason for the redirect - I think there's 2
things everyone, whatever their level of knowledge, knows about the
internet. First the little hand means a link you can click on and second if
you don't like a page you can hit back to return to where you came from.

I wouldn't mess with those 2 basic functions unless there's no
alternatives - my point is there is an alternative to the meta

Jon
 
Agreed!

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
WEBMASTER Resources(tm)

FrontPage Resources, WebCircle, MS KB Quick Links, etc.
==============================================
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top