Results 1 to 3 of 3

Thread: How to use php-cli with xampp?

  1. #1
    Join Date
    Mar 2009
    Beans
    10

    How to use php-cli with xampp?

    How do I use php from the command line? I am using xampp.
    When I tried to use it, it said unknown commoand. I installed php-cli using apt-get. Now when i use the php command in Terminal, I get:

    Code:
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/20060613+lfs/mysql.so' - /usr/lib/php5/20060613+lfs/mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/20060613+lfs/mysqli.so' - /usr/lib/php5/20060613+lfs/mysqli.so: cannot open shared object file: No such file or directory in Unknown on line 0
    PHP Warning:  PHP Startup: Unable to load dynamic library '/usr/lib/php5/20060613+lfs/pdo_mysql.so' - /usr/lib/php5/20060613+lfs/pdo_mysql.so: cannot open shared object file: No such file or directory in Unknown on line 0
    I am a total newbie (just 2 days). I did it in Windows, how do I do it here? forgive me if it has been asked earlier, i did not find it.

  2. #2
    Join Date
    Mar 2009
    Beans
    10

    Re: How to use php-cli with xampp?

    Somebody please reply. Its very important for me.

  3. #3
    Join Date
    Sep 2008
    Beans
    8

    Re: How to use php-cli with xampp?

    Since this topic insists on being number one in the Google results, here's the answer:

    /opt/lampp/bin/php is the command-line php installed by Xampp, so you need to add this line to your .profile:
    Code:
    PATH="/opt/lampp/bin:$PATH"

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
  •