Re: redirect / new website how to redirect old (google) links to new site ?



..oO(Jerry Stuckle)

Michael Fesser wrote:

Don't redirect. Configure your server to parse .html files for PHP.

It's unnecessary overhead to parse static html files for PHP code.

His files are not static, they contain PHP code. It's the URL that
should be static to avoid link rot and inconveniences for your visitors.

Now
what if you also want server side includes?

If you have PHP, you don't need SSI anymore.

But of course you can also use SSI if you like - just configure the
server to parse .html files for SSI directives. And if you want to use
it all at the same time, you can do that as well:

http://example.com/static.html
http://example.com/phpscript.html
http://example.com/perlscript.html
http://example.com/ssi.html

It just depends on the server configuration (in this case for example
with content negotiation and MultiViews).

A 301 redirect is recognized by all search engines and they
will replace the old URL with the new one.

New users will get the new URI and old ones will get redirected (and
most will also quickly learn the new URI).

That's a broken design. There are many valid reasons to keep all such
technical stuff out of URLs.

After a period of time, you can replace the 301 redirect with another
page which indicates "The page has moved...". That way the few
left-over people who haven't change the URI will do so.

Completely unnecessary, if you do it right from the beginning. If you
really think you need a filename extension in URLs, then use 'html'.
Of course no extension at all is even better.

Micha
.



Relevant Pages

  • Re: php within dhtml, is that possible?
    ... If your web server ... config to parse html files for php code. ...
    (comp.lang.php)
  • Re: redirect / new website how to redirect old (google) links to new site ?
    ... It's unnecessary overhead to parse static html files for PHP code. ... Telling the web server to process *all* .html files as php files is an unnecessary overhead. ...
    (comp.lang.php)
  • Re: File extensions
    ... Which will cause the server to work extra as it will parse all html files, ... And it can mess up caching - as html files are usually static, ... php files have "on the fly generation times" - unless one is careful. ... server load, as you mention, and bandwidth consequences. ...
    (alt.php)
  • Re: php within dhtml, is that possible?
    ... config to parse html files for php code. ...
    (comp.lang.php)
  • Re: PHP - HTML
    ... but setting up your server to parse .html files as PHP. ... this will create a lot of overhead on the server unnecessarily parsing non-html pages. ...
    (comp.lang.php)