Page 1 of 1

Aaaaaarrrrrrrgggggghhhhhh!!!!!

Posted: Sat Feb 01, 2003 4:20 pm
by BDKR
OK folks! I hope this helps someone else. And it's a good thing I allready shave my head!

If you are creating any command lines apps or utilities and need to parse user input, WATCH OUT! Perhaps there is something I don't know, but trying to test for command line args thar are zero, as in 0, is a pain in the arse! The only way to test for it is to first cast the argument to a string, then check if it's '0' as opposed to 0! What's up with that?! Is there something I'm missing here? Anybody got a large caliber handgun?

:evil:

Well, I got it figured, but I had to go get my arse kicked by the Sarge (Quake III) just to vent some steam.

BDKR

Posted: Sat Feb 01, 2003 4:31 pm
by mydimension
not to put a dampner on your already stressful time but did you ever try using the === operator? http://www.php.net/manual/en/language.o ... arison.php

Posted: Sat Feb 01, 2003 4:41 pm
by BDKR
not to put a dampner on your already stressful time...
No, that's really allright! I played Quake and made some coffee: things are good again. Besides, I just wanted to run my mouth a little.
...but did you ever try using the === operator?
As a matter of fact, no. 8O I'm kicking myself and laughing at the same time as I've allways known about that particular operator. Maybe it was the quiche (did I spell that right?) I had for lunch or too busy thinking about the Columbia disaster.

Cheers and thanx,
BDKR