FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Simpler way to validate form fields?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Simpler way to validate form fields? [message #179798 is a reply to message #179789] Wed, 05 December 2012 11:49 Go to previous messageGo to previous message
M. Strobel is currently offline  M. Strobel
Messages: 386
Registered: December 2011
Karma:
Senior Member
Am 05.12.2012 01:07, schrieb Jerry Stuckle:
> In most cases I prefer isset() over empty - an array element may be set but may not
> contain data. Those can be two different errors.

Same here. I think you should always use isset() in the first place, because clean
code does not access unset variables.

And if empty() is allowed depends on the case at hand.

/Str.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: when receiving the mail(php mail function), the variable's last value is getting converted to $ or # replacing the digit
Next Topic: How to Prevent Apache Server From Hanging while running a batch file?
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Thu Nov 28 09:43:07 GMT 2024

Total time taken to generate the page: 0.03998 seconds