LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   not able to run php cammand. Not able to find php (https://www.linuxquestions.org/questions/linux-newbie-8/not-able-to-run-php-cammand-not-able-to-find-php-680296/)

novinjaiswal 10-31-2008 10:46 AM

not able to run php cammand. Not able to find php
 
Hi Friends,

I am new to linux and php. I am installing cacti. for that PHP is needed.

I was able to fine /etc/php.d folder and php.ini file. Does it mean php is installed on my Linux box.

when i run php command using ssh it no such command found.

when I find for any php files in my system i return lots of files.

I am confused.
First I want to know php is installed or not.

If installed then which version is indstalled?

thanks in advance for all your help.

Novin

TB0ne 10-31-2008 12:06 PM

Quote:

Originally Posted by novinjaiswal (Post 3327406)
Hi Friends,

I am new to linux and php. I am installing cacti. for that PHP is needed.
I was able to fine /etc/php.d folder and php.ini file. Does it mean php is installed on my Linux box.
when i run php command using ssh it no such command found.
when I find for any php files in my system i return lots of files.
I am confused.
First I want to know php is installed or not.
If installed then which version is indstalled?
thanks in advance for all your help.
Novin

Yes, it's installed. If you're typing in php and it doesn't do anything, that means that PHP isn't in your path. Find php, add that path to yours, or just type in the full path name/command. Type in "man php" to see the options, I believe "php -v" will tell you what version you're running.

Check the docs at http://www.php.net.

novinjaiswal 10-31-2008 12:41 PM

Hi,

thanks for the reply I found following path.

cd /usr/local/php/bin

when i run php command i m getting following error.

bash: php: command not found

thanks
Novin

TB0ne 10-31-2008 01:19 PM

Quote:

Originally Posted by novinjaiswal (Post 3327486)
Hi,

thanks for the reply I found following path.

cd /usr/local/php/bin

when i run php command i m getting following error.

bash: php: command not found

thanks
Novin

Ok...as I said in my previous post, either put that path in your current path, or execute the full path/command. "/usr/local/php/bin/php -v"

novinjaiswal 10-31-2008 01:28 PM

Hi thanks

u r right its working thanks for your help.


All times are GMT -5. The time now is 10:14 PM.