Results 1 to 4 of 4

Thread: anyway to parse .html as .php?

  1. #1
    Registered Mike's Avatar
    Join Date
    May 2003
    Location
    UK
    Posts
    2,755

    anyway to parse .html as .php?

    Hi all,

    A lot of people going to my website are visiting the old .html address'. So I wondered if there was anyway to make it so if they visited say medical.html, it would automaticly send them to medical.php? You could just use redirects, I know, but I wondered if you could parse .html files like this?

    Thanks,
    Mike
    Don't you just love free internet games ?

  2. #2
    Chronic Entrepreneur
    Join Date
    Nov 2003
    Location
    Tulsa, Oklahoma, USA
    Posts
    1,112
    You could add this to .htaccess :

    AddType application/x-httpd-php .html

    This will cause the .html files to be parsed as php files. The drawback to doing this is that it will slow everything down because it sends all .html pages through the php parser, even if they contain no php.

  3. #3
    Senior Member chromate's Avatar
    Join Date
    Aug 2003
    Location
    UK
    Posts
    2,348
    If you're already established using .html's then I would continue to use them and set up htaccess so they get parsed as Westech said.

    This will save you from any PR problems that could arise from changing to a php extension.

  4. #4
    Registered Mike's Avatar
    Join Date
    May 2003
    Location
    UK
    Posts
    2,755
    Hmm..ok, thanks guys
    Don't you just love free internet games ?

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •