LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 06-21-2007, 02:46 AM   #1
Hondro
Member
 
Registered: Mar 2006
Location: Lithuania
Distribution: Slackware-12.2
Posts: 102

Rep: Reputation: 15
Problems running PHP script in command line


Hi, i need to run one PHP script from linux command line, but when i try to do it, i have got:

Quote:
PHP Fatal error: Call to undefined function: dbase_open()
When i try to run this script from other PC (Apache) which is in my lan network, everything goes good.

I have slackware 10.2, apache 1.3.7, php 4.4.4

Thanks in advance
 
Old 06-21-2007, 04:16 AM   #2
Guttorm
Senior Member
 
Registered: Dec 2003
Location: Trondheim, Norway
Distribution: Debian and Ubuntu
Posts: 1,148

Rep: Reputation: 236Reputation: 236Reputation: 236
Hi

I don't know Slackware, but it's common to use two different php.ini files - one for Apache and one for command line interface (CLI). On my system I have "/etc/php4/apache/php.ini" and "/etc/php4/cli/php.ini". It might be useful to use a different configuration for the two, but it can be confusing. I usually delete the cli version and make a symlink to the other instead. So when I change one, the other is also changed:

rm /etc/php4/cli/php.ini
ln -s /etc/php4/apache/php.ini /etc/php4/cli/php.ini
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems running PHP scrip in command line Hondro Programming 0 06-21-2007 02:39 AM
i get an error message running php script inside a cgi script. repolona Linux - Software 0 02-22-2007 09:10 PM
auto running a script from command line millionknives Slackware 7 10-03-2005 10:07 PM
php from command line odious1 Linux - Software 4 05-03-2004 12:31 AM
problems running php script rhuser Linux - Software 5 02-14-2003 01:01 PM


All times are GMT -5. The time now is 09:06 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration