PHP is not displaying any results in the browser

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • TatianaCoban
    New Member
    • Jan 2010
    • 2

    PHP is not displaying any results in the browser

    i am learning PHP, i have checked 1000s of time, my php code is wrote correctly, but when i try to preview it in the browser - it shows as a blank page. If i take a look at the Page source - it shows the php code.
    What do i do wrong, and how can i fix it.
    Thanks.
    I have windows vista and i work with cs4.

    This is the code that i use:

    Code:
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>
    </head>
    
    <body>
    <?php
    $name = "Tatiana";
    
    echo "$name";
    ?>
    </body>
    </html>
    Last edited by Dormilich; Jan 19 '10, 08:20 PM. Reason: Please use [code] tags when posting code
  • aktar
    New Member
    • Jul 2006
    • 105

    #2
    Hi, this looks like a problem with your http server set up, not the actual php code.

    First and foremost, I need to ask:

    1) do you actually have php installed on your computer?
    2) do you have a Http server such as Apach or IIS installed on your computer?
    3) if so, is the Http server configured properly so that it handles php pages correctly?

    Comment

    • TatianaCoban
      New Member
      • Jan 2010
      • 2

      #3
      Hi, Thanks for reply,
      I do have Apach on my comp ( I don't know if it matters, but it says <Win32> ) and i have vista
      --- I'm sorry if my questions might seem very simple to you - but I'm new to this

      What do you mean when you ask me if I have Php installed on my comp?
      Last edited by Dormilich; Jan 19 '10, 08:21 PM. Reason: removed unnecessary quote

      Comment

      • aktar
        New Member
        • Jul 2006
        • 105

        #4
        Php is the program that interprets your code and sends the output to the Http server, in your case, Apache, in in-turns sends it to the browser for display.

        Here is a good tutorial about how to install and configure PHP and Apache on Windows:

        Comment

        Working...