TutorialGuru: Free Tutorials for your life
Search TutorialGuru:
Free TutorialEdit This Tutorial

How to Use Meta Tags to Refresh a Page or Redirect a Page

Meta tags are specific HTML commands which allow you to do a certain function. One of the handiest META tags is the refresh META tag to refresh a web page or redirect to another web page. Learn how to use META tags in this free tutorials.

Tutorial

Meta Tags are handy commands which allow you to set a description for a webpage, create keywords on a page, or refresh a page. This tutorials teaches you how to use META tags to refresh a webpage, redirect to a different webpage or URL, or pause and then redirect to a different page or URL.

Refreshing a Webpage

If you have content which needs refreshing frequently or you just want your page to automatically refresh after a given amount of time, you can use the refresh Meta command to reload the web page in the user's browser. The general format for this command is:

<meta http-equiv="refresh" content="120">

This command will refresh (reload) the current web page every 120 seconds.

The meta tag is the actual HTML tag. This tag should typically be in the portion of your web page, though it can be in the body for most web browsers.

http-equiv="refresh" is an attribute of the meta tag telling the web server that this page will be refresh or redirected.

content="120" is the attribute with the number of second before the page should be reloaded. This example page will be refreshed in 120 seconds, if the command was content="600", the page would be refreshed in 600 seconds - or 10 minutes.

Redirecting to Another Webpage

Redirecting to another webpage is very similar to the refresh command. The format of this tag is:

<meta http-equiv="refresh" content="5;url=http://www.learnthat.com/">

The difference in this meta tag is content="5;http://www.learnthat.com/" this command will refresh the current webpage and redirect it to the http://www.learnthat.com URL in 5 seconds.

For More Information

For a full META tags tutorial, please visit Learnthat.com for a free META tags tutorial describing the refresh command, keywords, description META tags.

by jreis on Thursday, May 19, 2005

 

 

Information About This Tutorial
Tutorial Requestor: jreis
Request Created: 5/19/2005 7:00:12 AM
Request Description:  
2893
 
© 2005 That Network. All Rights Reserved. Part of That Network.
This page last updated 5/19/2005 7:41:37 AM .