Results 1 to 2 of 2
Hello all. I have a script that has the line it and am trying to run that script as a cron job. Code: firefox ~/callGlenn.html & sleep 20 It works ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 03-10-2006 #1
- Join Date
- Feb 2004
- I'd rather be in Hawaii
Calling website from cron job.
I have a script that has the line it and am trying to run that script as a cron job.
firefox ~/callGlenn.html & sleep 20
xterm: DISPLAY is not set
How do I set the display for xterm. I looked thorugh the man page, but it only gave a very vague description of what the display actually was for.
If any one could tell me how to accomplish this I would be very grateful. Or if there is a method other than using a web browser to basically "click a link" on some webpage I would love to hear about it.
Thanks in advance.
- 03-10-2006 #2
I would imagine that $DISPLAY is the variable holding the address of the X Server, and since cron is not being run from an X Server, this is empty.
Having said that, I would imagine that you could call a script like the following from cron (assuming, of course, that you have an X Server running somewhere):
DISPLAY=:0.0 firefox ~/callGlenn.html & ffpid=$! sleep 20 kill $ffpid
wget --spider -i ~/callGlenn.html
Try these and lemme know if they work.