Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End How to put a .php script in .html file

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #37380
    Mary
    Participant

    How to put a .php script in .html file …?

    THX

    #100117
    Senff
    Participant

    If the HTML file has the extension .PHP, then it’s still HTML but the server will recognize it as a PHP file, and execute all PHP code in it.

    #100121
    Mikefmi
    Member

    First save the file as .php instead of .html

    Ensure that your php script that you past into your html, that has now been saved as .php is still wrapped in

    To view the php file though, you will have to be on a server that runs php and apache, or you can run it locally by downloading mamp(mac) or wamp(windows).

    MAMP: http://www.mamp.info/en/index.html
    WAMP: http://www.wampserver.com/en/

    Tutorial about MAMP by chris: https://css-tricks.com/video-screencasts/86-mamp/

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘Back End’ is closed to new topics and replies.