4
I have a PHP script that I currently leave running with an open browser, with the command below:
<meta HTTP-EQUIV="refresh" CONTENT="1800">
Despite the mémoria problems that the browser consumes, it was running smoothly. Now I need to develop 3 more scripts that will also run from time to time.
Is there any way to run the script via task manager?
I did a test with prompt, but I did not succeed, because regardless of the script, it always returns a parse error that does not exist.
Parse error: syntax error, unexpected end of file in C:\wamp\www\reservas\Enviar
EmailLembrete.php on line 281
C:\wamp\bin\php\php5.5.12>php c:\wamp\www\reservas\EnviarEmailLembrete.php
Switching to localhost:
C:\wamp\bin\php\php5.5.12>php -f http://localhost/reservas/EnviarEmailLembrete.p
hp
Could not open input file: http://localhost/reservas/EnviarEmailLembrete.php
Code Jsfiddle
Just put
php -f "c:\wamp\www\reservas\EnviarEmail.php"
at prompt does not work?– rray
No, it gives the error I put in the question, in any script I run...
– Diego
What’s on that line? Maybe it has some invisible character. If you have Notepad++ open the file go to the menu
view>show symblos>show all symbols.
– rray
With the textpad it only shows blank spaces, has nothing on this line...
– Diego
Gambiarra:
chrome.exe "c:\wamp\www\reservas\EnviarEmail.php"
– David
Removing space from a different result?
– rray
David, it worked that way, but then he called the browser and it worked fine, but then I come back to the memory problem. @rray I removed the spaces, but nothing changed.
– Diego
Not to be boring :D, could do two more tests, maybe you have an environment problem. 1 - create a simple script a
echo 'ola '. mt_rand(1,10000)
and run it via prompt and see if the same error happens. 2 - If possible try running the original script in another php installation. I say this because another saw a user question q could not install a lib(Intl) had done the right process and was not going at all, so I suggested that he swapped the wamp for the xampp and it worked. The wamp and easyPHP seem to be half zicados ...– rray