Page 1 of 1

"Could not open input file" error on "php -f

Posted: Mon Oct 29, 2007 10:50 am
by php_ghost
Hi everyone,

I'm having problems running this command.

whenever I open a url using "php -f" in the command line it always shows the message "Could not open input file."

ex.
php -f "http://www.yahoo.com"

Could not open input file : http//www.yahoo.com

What could be the problem? :cry:

TIA

Posted: Mon Oct 29, 2007 11:03 am
by feyd
It's not a LOCAL file.

Posted: Mon Oct 29, 2007 11:11 am
by php_ghost
but it works fine before

Posted: Mon Oct 29, 2007 11:16 am
by php_ghost
another thing is the "file" function

Code: Select all

file("url");
from one of my php scripts also stopped working.

Posted: Mon Oct 29, 2007 11:45 am
by feyd
You probably have allow_url_fopen off or allow_include_url off (if you're running a more recent version of PHP 5)

Re: "Could not open input file" error on "php -f

Posted: Wed Oct 29, 2008 11:18 am
by drunkinmastaray
I had the same problem.... If you do a copy and paste of the command "php –f" for some odd reason the "-" character will not be seen as a dash in the Cron Daemon, instead it is seen as "â€". I had to type it out and VIOLA... it works. At least it worked for me. :drunk: