New to PHP

Discussion in 'Installation/Configuration' started by Carlo Gambino, Jul 21, 2008.

  1. Carlo Gambino

    Carlo Gambino New Member

    Hello!

    I made a small php file and uploaded it to my server to ensure I've set everything up correctly:

    Code:
    <HTML>
    <HEAD>
    <TITLE>PHP Testing</TITLE>
    </HEAD>
    <BODY>
    <?php
    echo "if this works, we <i>really</i> did it!";
    ?>
    </BODY>
    </HTML>
    and confirmed the file was in the correct directory. When I call the file in a browser, I see the code, not the echo'd text. The code looks correct to me, but I am new to PHP. Is it the code or the configuration?
     
  2. topdog

    topdog Active Member

    your web server is not setup to interpret php files, you need to fix that.
     
  3. falko

    falko Super Moderator Howtoforge Staff

    Which tutorial did you follow to set the server up?
     
  4. Carlo Gambino

    Carlo Gambino New Member

  5. falko

    falko Super Moderator Howtoforge Staff

    I guess you also followed chapter 17.1 (Disable PHP Globally) of that tutorial? If you're not using ISPConfig, undo that chapter, and PHP will work again.
     
  6. Carlo Gambino

    Carlo Gambino New Member

    Thanks for pointing out the oversight!

    I even told myself not to do this while I was reading the tutorial.. I must have been on auto pilot.

    php works, thanks for the help!
     

Share This Page