Reply to meta redirect - on removing .htm extension, Firefox displays HTML - Why?

Your name:

Reply:


Posted by David Smithz on 11/25/20 11:46

Hi there,

I wanted to implement a meta redirect so that when users visiting a website
just type the following for example

www.example.com/downloads

instead of

www.example.com/downloads.htm

I wanted the visitor to be redirected to the .htm page.

I therefore created a very simple page which just has a meta tag redirect
which does the appropriate redirect.

This worked fine, however, when I remove the .htm file name from the file,
and then view it on Firefox browser, it actually just displays the HTML
code.
How can I make it work so it does not should the HTML code?

An example of the code I use is below:

**********************************************
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="refresh" content="0;
URL=http://www.example.com/downloads.htm">
<title>example - downloads redirect</title>
</head>

<body>
<p>...redirect to download page...</p>
<p>or click below if your browser does not support redirects</p>
<p><a href="./downloads.htm">downloads.htm</a></p>
<p>&nbsp;</p>
</body>
</html>
*********************************************

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация