2.11.6. Running a script via wget

If you need to add a task to run a script via wget, you should do it like this:

/usr/bin/wget -t 1 -O - http://site.ua/script.php

If parameters are passed in the URL you are using, wget may not process them and you will not get the result you expected. In this case, the transmitted URL must be enclosed in single quotes:

/usr/bin/wget -t 1 -O - 'http://site.ua/script.php?p1=a&p2=b'
At adding or editing a cron task, instead of a command, you can simply specify the desired URL and when saving the changes, the system will automatically generate a standard wget command with this URL in single quotes.
Content