Re: [PHP] Execute a PHP script from unix (crontab)
do you mean perl?!? - Original Message - From: Augusto Cesar Castoldi [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 16, 2001 1:04 AM Subject: [PHP] Execute a PHP script from unix (crontab) Hi. How can I execute a php script from the unix? like pearl it's (pearl file), but in unix we don't have a executable of php, it's a module ,right? I should compile the script first? I want this to add to crontab to make backup of my mysql automaticly. thanks. Augusto -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Execute a PHP script from unix (crontab)
From: Augusto Cesar Castoldi [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 16, 2001 1:04 AM Subject: [PHP] Execute a PHP script from unix (crontab) How can I execute a php script from the unix? like perl it's (perl file), but in unix we don't have a executable of php, it's a module ,right? Same idea as Perl, start with a shebang line to tell it where to find the interpreter: #!/usr/local/bin/php ?php // your script here... ? I should compile the script first? Nope, no need... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Execute a PHP script from unix (crontab)
Hi First get your PHP script working correctly...;-) The use crontab to run lynx (as a browser that runs the PHP script for you). Here's an example crontab line (works for me) that even gets lynx to handle an .htaccess protected_dir ;-): 5 5 * * * /usr/local/bin/lynx -dump -nolog -auth=userid:passwd httpd://mydomain.com/protected_dir//myphpscript.php /dev/null Hope that helps, Tom Henry Reductor wrote: do you mean perl?!? - Original Message - From: Augusto Cesar Castoldi [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 16, 2001 1:04 AM Subject: [PHP] Execute a PHP script from unix (crontab) Hi. How can I execute a php script from the unix? like pearl it's (pearl file), but in unix we don't have a executable of php, it's a module ,right? I should compile the script first? I want this to add to crontab to make backup of my mysql automaticly. thanks. Augusto -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Execute a PHP script from unix (crontab)
Hi, There are basically two ways of doing this. Use lynx : lynx --dump http_address_to_file or Compile php as a cgi binary. You should select them based on your need. Kunal - Original Message - From: Hugh Bothwell [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, August 15, 2001 9:30 PM Subject: Re: [PHP] Execute a PHP script from unix (crontab) From: Augusto Cesar Castoldi [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 16, 2001 1:04 AM Subject: [PHP] Execute a PHP script from unix (crontab) How can I execute a php script from the unix? like perl it's (perl file), but in unix we don't have a executable of php, it's a module ,right? Same idea as Perl, start with a shebang line to tell it where to find the interpreter: #!/usr/local/bin/php ?php // your script here... ? I should compile the script first? Nope, no need... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Execute a PHP script from unix (crontab)
Why not use the tool built for the job? mysqldump will allow saving both data and structure. http://www.mysql.com/doc/m/y/mysqldump.html -Original Message- From: Kunal Jhunjhunwala [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 15, 2001 11:05 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Execute a PHP script from unix (crontab) Hi, There are basically two ways of doing this. Use lynx : lynx --dump http_address_to_file or Compile php as a cgi binary. You should select them based on your need. Kunal - Original Message - From: Hugh Bothwell [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, August 15, 2001 9:30 PM Subject: Re: [PHP] Execute a PHP script from unix (crontab) From: Augusto Cesar Castoldi [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 16, 2001 1:04 AM Subject: [PHP] Execute a PHP script from unix (crontab) How can I execute a php script from the unix? like perl it's (perl file), but in unix we don't have a executable of php, it's a module ,right? Same idea as Perl, start with a shebang line to tell it where to find the interpreter: #!/usr/local/bin/php ?php // your script here... ? I should compile the script first? Nope, no need... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]