Archive | October, 2007

Crontab : Disable email notifications

5. October 2007

0 Comments

By default, when you schedule a cronjob, the cron daemon will email the administrator with the results of the schedule. You can easily turn off email reporting by appending the string “>/dev/null 2>&1” (without quotes) to the end of the command. Like this : wget http://domain.com >/dev/null 2>&1 Hope this helps!

Continue reading...

PHP : Random string with numbers and letters

1. October 2007

7 Comments

I thought that some of you might find it useful to learn how to generate a string with random numbers and letters. I wrote a quick function for generating a string like this. See it below : function genRandomString() {     $length = 10;     $characters = ‘0123456789abcdefghijklmnopqrstuvwxyz’;     $string = ”;         for [...]

Continue reading...