Results 1 to 3 of 3

Thread: PHP beginner question.

  1. #1
    Join Date
    Mar 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default PHP beginner question.

    I installed XAMPP and localhost/helloworld.php. works in the browser. But when I click on 'helloworld.php' in htdocs it seems to work but does not in fact execute the php scripts, just the html.

    Why can't I just click on a file in htdocs and get it to execute? Maybe there is some setting that needs to be fixed?
    Last edited by fred1; 03-27-2010 at 07:19 PM. Reason: sp

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    That's the way it's supposed to work. Unless XAMPP and the local host are active and you navigate to the pages using the localhost address, your local PHP 'sandbox' is inaccessible. With or without all that, you can always view the pages as ordinary files by navigating to them directly. But of course, since they are no longer being viewed via the XAMPP server, there will be no PHP interpreter available.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Mar 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks.

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
  •