I have EasyPHP 5.3.6.0 local server, (with PHP 5.3.6) and it works fine in my browser. However, using the PHP executable on the command line doesn’t work without problems.
I have noticed that command line didn’t load the php.ini file:
C:\\> php --ini
Output:
Configuration File (php.ini) Path: C:\Windows
Loaded Configuration File: (none)
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
Btw, there isn’t a php.ini file in the ‘C:\Windows’ directory. My server (apparently) uses the ‘C:\Program Files (x86)\EasyPHP-5.3.6.0\apache\php.ini’ file.
When I translate PHP files I get a warning:
Warning: date_default_timezone_get(): It is not safe to rely on the system’s timezone settings. You
are required to use the date.timezone setting or the date_default_timezone_set() function. In case
you used any of those methods and you are still getting this warning, you most likely misspelled th
e timezone identifier. We selected ‘Europe/Helsinki’ for ‘3.0/DST’ instead in C:\Program Files (x86)
\EasyPHP-5.3.6.0\home\timezone.inc.php on line 2
I got no warnings when I used the ‘php -c …’ command, but I’d like permanently set an .ini file to use with a command line.
phpis just saying that’s where it expects thephp.inifile to be. One option is to copy the ones from the web server and modify them as necessary.