On Tuesday 09 September 2003 12:57, James Hatridge wrote:
Ok, I check that and changed it to backticks, it changed the error I got.
Sorry - I meant backticks if you're just using the command by itself: $return=`program`; echo $return; for instance. If you want to use exec(), you use something like: exec("program",$return); foreach ($return as $line) echo "$line\n"; This should give a printout of the output lines from the $return array, so you can see what the alleged execution is doing. You could also just use passthru("program"); to have the output sent direct to the browser. $return=system("program") is similar. You should probably have a good read of the onsite manual, because there are various user annotations on it. And also be prepared to spend a bit of time exploring what works on your system - in my experience, most PCs are set up slightly differently, because people tend to use their own methods and locations for saved files (eg I personally would not store AUD.txt in the mysql dir). So you may have to keep looking at things like permissions. In particular, the webserver (wwwrun.nogroup in SuSE) may need to be allowed access to the file and to the directory you want it stored in, never mind the dir where the program is. HTH
The euro-update.program is just a small bash file. I've got it running very good at the command line. So I know that it works. If you had a bash file to run, how would you do it?
I know what options I would try, but I approach all these things on the basis that they will never work first time around. It's a bit like getting your bearings in a strange town. -- Best wishes Kevin Donnelly www.kyfieithu.co.uk - Meddalwedd Rydd yn Gymraeg