Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread John Nichel
John Nichel wrote: $output = array(); exec ( "locate whatever" $output ); And loop thru the $output array. It's all in the manual http://us4.php.net/manual/en/function.exec.php Oops, I forgot the comma... exec ( "locate whatever", $output ); -- By-Tor.com It's all about the Rush http://www.by-t

RE: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Jay Blanchard
[snip] According to the manual, exec() "does not output anything. It simply returns the last line from the result of the command." The OP wants to display the output of 'locate' to the browser, so he should use passthru(), which displays all raw output. [/snip] Cool -- PHP General Mailing

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread John Nichel
BOOT wrote: Thanks for all the replies. Regarding security, I use a script to ensure (hopefully LOL) that only requests from inside our network are accepted both hostnames and IP's are checked. I did find lonewolf's reply most usefull, but now I need to come up with way to make each result (a h

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread lonewolf
;\n" character very well, or I messed up in the code somewhere. What would the explode look like for this: "; echo $items[0]; echo ""; ?> - Original Message - From: Ben Ramsey <[EMAIL PROTECTED]> Date: Friday, September 3, 2004 2:44 pm Subject: Re: [PHP] PHP

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread BOOT
Thanks for all the replies. Regarding security, I use a script to ensure (hopefully LOL) that only requests from inside our network are accepted both hostnames and IP's are checked. I did find lonewolf's reply most usefull, but now I need to come up with way to make each result (a href...) an

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Greg Donald
On Fri, 2004-09-03 at 12:46, BOOT wrote: > Does anyone have a script that can be used to call linux's locate command > and display the results in a browser? -- Greg Donald -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Jason Davidson
I assume you mean locating something on the server, as this would be a serious breech of security otherwise. anyways, bickticks will run shell comand line programs and return the output.. ie print `locate myFile'`; jason "BOOT" <[EMAIL PROTECTED]> wrote: > > Does anyone have a script that can

RE: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Paul Fine
Great thanks... now I just work on a form and a hrefs -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: September 3, 2004 1:49 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [PHP] PHP Linux "locate" to html script? "; ec

RE: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Jay Blanchard
[snip] Thanks but that's no good if there are multiple results! ... Does anyone have a script that can be used to call linux's locate command and display the results in a browser? ... [/snip] exec("locate foo"); [/snip] So you want something like while(bar == exec("locate foo")) barArra

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread lonewolf
"; echo $items; echo ""; ?> - Original Message - From: BOOT <[EMAIL PROTECTED]> Date: Friday, September 3, 2004 1:46 pm Subject: [PHP] PHP Linux "locate" to html script? > Does anyone have a script that can be used to call linux's locate >

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Ben Ramsey
According to the manual, exec() "does not output anything. It simply returns the last line from the result of the command." The OP wants to display the output of 'locate' to the browser, so he should use passthru(), which displays all raw output. Jay Blanchard wrote: [snip] Does anyone have a s

RE: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Paul Fine
Thanks but that's no good if there are multiple results! -Original Message- From: Jay Blanchard [mailto:[EMAIL PROTECTED] Sent: September 3, 2004 1:40 PM To: BOOT; [EMAIL PROTECTED] Subject: RE: [PHP] PHP Linux "locate" to html script? [snip] Does anyone have a script t

RE: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread Jay Blanchard
[snip] Does anyone have a script that can be used to call linux's locate command and display the results in a browser? I don't think it would be that hard and will make an effort today... [/snip] exec("locate foo"); -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://

Re: [PHP] PHP Linux "locate" to html script?

2004-09-03 Thread John Nichel
BOOT wrote: Does anyone have a script that can be used to call linux's locate command and display the results in a browser? I don't think it would be that hard and will make an effort today... Thanks! http://us4.php.net/manual/en/function.exec.php -- John C. Nichel ÜberGeek KegWorks.com 716.856.967

[PHP] PHP Linux "locate" to html script?

2004-09-03 Thread BOOT
Does anyone have a script that can be used to call linux's locate command and display the results in a browser? I don't think it would be that hard and will make an effort today... Thanks! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php