Passing parameters from command line.

From: Date: Thu, 03 Aug 2000 09:54:34 +0000
Subject: Passing parameters from command line.
Groups: php.general 
Request: Send a blank email to php-general+get-9897@lists.php.net to get a copy of this message
Hi All, I make php script which update database daily so i need to put it in crontab, but script needs one parameter ( like http://some.domain.com/script.php?param=val). I cann't use lynx or staff like that because script need to be outside web tree. I read previous posts and find that Rasmus Lerdorf suggests this: QUERY_STRING="id=page1" php -q source.php3 > dest.html I try this out on Slackware 7.0 and this works fine, but on FreeBSD 3.3 where it needs to be, I have error: QUERY_STRING=id=page1: Command not found. Maybe someone knows what i need to reconfigure in FreeBSD, PHP4 or there is some another posibility to pass parameters? Any suggestions welcome. Aigars

« previous php.general (#9897) next »