escapeshellcmd

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
alex.barylski
DevNet Evangelist
Posts: 6267
Joined: Tue Dec 21, 2004 5:00 pm
Location: Winnipeg

escapeshellcmd

Post by alex.barylski »

is it nessecary to call this function on data passed to functions like glob()

I found a recursive directory lister in PHP comments and it uses this function to escape data

Problem is on Windows the \ is used as a directory delimiter and the above function removes that character?

When I comment out the function everything works fine :(

Do I have to regex the \ to / first then call that function? Is that even a good way of doing this?

Is that function really needed on glob, etc???

p.s-No it's generally a good idea type replies please...strictly yes or no...

Cheers :)
Baby Kosub
Forum Newbie
Posts: 3
Joined: Fri May 05, 2006 10:12 pm

Post by Baby Kosub »

the answer would be no. i looked into a peice of php that uses shell and it does not have that.

the program is webalizer btw
Post Reply