1
tmreg
cron jobs for dummies
  • 2007/5/11 1:14

  • tmreg

  • Not too shy to talk

  • Posts: 137

  • Since: 2006/7/20


OK, I know the XOOPS forums is probable not the place for this but......

I am trying to wrap some type of php analytics program into a XOOPS module for a client. this client is a non-profit whos login area will be restricted to employees and board members. If it were up to me, I could set them up some sort of simple stats program so the "inside guys" can keep track of their web site usage. I have found a stats program that I got to work with the exception that I need to initiate a "cron job" to run an update file at midnight every day.

Not knowing even the right questions to ask, can someone point me in the right direction. Just to make things easier, I am using GoDaddy.com and have no access above my public folder.

I would appreciate any assistance.
-Matt

2
JMorris
Re: cron jobs for dummies
  • 2007/5/11 2:49

  • JMorris

  • XOOPS is my life!

  • Posts: 2722

  • Since: 2004/4/11


Log in via SSH
Type "crontab -e" without the quotes, hit enter
In the editor, type "i" without quotes then enter the following...

If you have PHP compiled with CLI (preferred):
* * * /full/path/to/file.php 2>&1


If you have PHP compiled without CLI:
* * * lynx -dump http://domain.com/file.php 2>&1


After you input the following, type ":wq" without the quotes to save your crontab file and you're done.

HTH.

James
Insanity can be defined as "doing the same thing over and over and expecting different results."

Stupidity is not a crime. Therefore, you are free to go.

3
attock
Re: cron jobs for dummies
  • 2007/5/23 21:21

  • attock

  • Not too shy to talk

  • Posts: 138

  • Since: 2006/8/20


I dont you can setup cron jobs on godaddy.com ?


You don't have to take it, its just my suggestion: google analytics have some kewl stats, with graphs and flashy stats.

4
paulizaz
Re: cron jobs for dummies
  • 2007/5/30 10:43

  • paulizaz

  • Not too shy to talk

  • Posts: 120

  • Since: 2007/1/18


Hey, im a bit lost on how to find this information out, so I hope you can help.


Do you know if a CRON Job editor exists in XOOPS.

The reason for this is to potentially add cron jobs that recreate 'Xhelp' tickets for scheduled events that will appear on an uptodate 'Today' page.

Many thanks,

5
Dave_L
Re: cron jobs for dummies
  • 2007/5/30 13:15

  • Dave_L

  • XOOPS is my life!

  • Posts: 2277

  • Since: 2003/11/7


Quote:
* * * /full/path/to/file.php 2>&1


That will run once a minute from 00:00 to 00:59.

To run at midnight only:

Quote:
0 0 * * * /full/path/to/file.php 2>&1

6
JMorris
Re: cron jobs for dummies
  • 2007/5/30 13:45

  • JMorris

  • XOOPS is my life!

  • Posts: 2722

  • Since: 2004/4/11


Whooops! Thanks Dave!
Insanity can be defined as "doing the same thing over and over and expecting different results."

Stupidity is not a crime. Therefore, you are free to go.

Login

Who's Online

160 user(s) are online (110 user(s) are browsing Support Forums)


Members: 0


Guests: 160


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Mar 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits