Results 1 to 7 of 7

Thread: I need help to set up php

  1. #1
    Join Date
    Dec 2007
    Beans
    1,057

    I need help to set up php

    I have used lots of time to make php work on ubuntu without a success.
    I used NetBeans
    I have follow this link
    http://www.netbeans.org/kb/docs/php/...nt-ubuntu.html
    then create a little project when I run my browser point to

    http://localhost/PhpProject1/index.php
    I always get the error
    404 Not Found

    thanks

  2. #2
    Join Date
    Jun 2007
    Location
    Maryland, US
    Beans
    6,267
    Distro
    Kubuntu

    Re: I need help to set up php

    I had a similar problem once before. I do not know if what I did to resolve the issue was correct or not, but this is what I did:

    1. sudo vi /etc/apache2/sites-available/default

    2. Change the following:
    Code:
         #DocumentRoot /var/www
         DocumentRoot /home/user
    3. Change the following:
    Code:
         #<Directory /var/www>
         <Directory /home/user>
    4. Save the file.

    Replace the "user" above with your userid.

    That should do it. Try running your script again via the browser.

  3. #3
    Join Date
    Dec 2007
    Beans
    1,057

    Re: I need help to set up php

    when I run sudo /etc/init.d/apache2 restart

    I get the following error

    test@ubuntu:~$ gksudo gedit /etc/apache2/sites-available/mysite
    test@ubuntu:~$ sudo /etc/init.d/apache2 restart
    * Restarting web server apache2 (98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
    no listening sockets available, shutting down
    Unable to open logs

  4. #4
    Join Date
    May 2008
    Beans
    Hidden!

    Re: I need help to set up php

    Quote Originally Posted by hoboy View Post
    test@ubuntu:~$ sudo /etc/init.d/apache2 restart
    * Restarting web server apache2 (98)Address already in use: make_sock: could not bind to address 0.0.0.0:80
    no listening sockets available, shutting down
    Unable to open logs
    It looks like another server is already trying to bind to port 80, so Apache can't. Try the 'netstat -l' command to find out what.

    I don't know what the last line ("Unable to open logs") means.

  5. #5
    Join Date
    Dec 2007
    Beans
    1,057

    Re: I need help to set up php

    I have installed xampp now the problem is how to set ubuntu to deploy php projects under it.now when I create php project in netbeans then run it inside the ide I get the following error
    The requested URL /NetBeansProjects/index.php was not found on this server.

  6. #6
    Join Date
    Dec 2007
    Beans
    1,057

    Re: I need help to set up php

    problem is solved

  7. #7
    Join Date
    Jun 2007
    Location
    Maryland, US
    Beans
    6,267
    Distro
    Kubuntu

    Re: I need help to set up php

    Quote Originally Posted by hoboy View Post
    problem is solved
    Thanks for sharing your solution!

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
  •