1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How do you convert PHP files into HTML files

Discussion in 'PHP' started by Inquiring Mind, Mar 9, 2007.

  1. #1
    I am able to to convert HTML files into PHP files by saving .htm files as .php without a problem.
    But everytime I try to convert PHP files into HTM, it doesn't come out right.
    I use netscape navigator to edit my files.
    How do you convert PHP files into HTML files without the page looking like wrong?
     
    Inquiring Mind, Mar 9, 2007 IP
  2. britishguy

    britishguy Prominent Member

    Messages:
    7,949
    Likes Received:
    892
    Best Answers:
    0
    Trophy Points:
    360
    #2
    Mod Re-Write
     
    britishguy, Mar 9, 2007 IP
  3. nico_swd

    nico_swd Prominent Member

    Messages:
    4,153
    Likes Received:
    344
    Best Answers:
    18
    Trophy Points:
    375
    #3
    Either mod-rewrite, or this in a .htaccess file.

    
    AddType application/x-httpd-php .html
    
    Code (markup):
     
    nico_swd, Mar 9, 2007 IP
  4. Inquiring Mind

    Inquiring Mind Peon

    Messages:
    19
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Thanks for the info.
    I am still loss.
    How would you save a page by the name of test.php into test.htm using the code you just posted (AddType application/x-httpd-php .html)
    I want to be able to re-design the test.php page and save it as test.htm
     
    Inquiring Mind, Mar 9, 2007 IP
  5. nico_swd

    nico_swd Prominent Member

    Messages:
    4,153
    Likes Received:
    344
    Best Answers:
    18
    Trophy Points:
    375
    #5
    Create a new file called .htaccess (with the dot), and copy and past this line of code I gave you in there. Then drop the file in your root directory, and all HTML files should be parsed as PHP files.
     
    nico_swd, Mar 9, 2007 IP
  6. Inquiring Mind

    Inquiring Mind Peon

    Messages:
    19
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #6
    I don't think I am clear enough. My goal is web design. I only know how to design using netscape navigator copy and paste strategy. That is why I want to convert PHP into HTM. It not a matter of uploading to the server. It's a matter of me not being able to design pages in straight html format. I don't know how to go into wordpad or notepad to design a page. But I can create great looking pages using netscape copy and paste stategy. I am trying to save PHP pages that already existed as htm pages in order for me to be able to design them.
     
    Inquiring Mind, Mar 9, 2007 IP
  7. Freewebspace

    Freewebspace Notable Member

    Messages:
    6,213
    Likes Received:
    370
    Best Answers:
    0
    Trophy Points:
    275
    #7
    I think just type

    www.xxxxx.com/test.php in your browser

    when the webpage opens save it as test.html

    Thats it
     
    Freewebspace, Mar 9, 2007 IP
  8. Inquiring Mind

    Inquiring Mind Peon

    Messages:
    19
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    1) when the webpage opened, I saved it as test.html
    2) When I open the new test.html page it looks good.
    3) When I try to edit it with netscape navigator, I get a blank page.

    How do I can I make the page stay the same in order for me to edit it.
     
    Inquiring Mind, Mar 9, 2007 IP
  9. rahuldroy

    rahuldroy Peon

    Messages:
    33
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #9
    try uploading it to you host and see if it actually works there, that what counts.
     
    rahuldroy, May 9, 2008 IP
  10. mukeshkapoor41

    mukeshkapoor41 Peon

    Messages:
    30
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    best advice..simple and quick..
     
    mukeshkapoor41, May 9, 2008 IP