|
|
||||||
|
||||||
| Index Link To US Private Messages Archive FAQ RSS | ||||||
| Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome. |
Share Thread: & Tags
|
||||
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
I understand that the isset () function tests if a variable has a value. But I do not understand that this includes 0, false or an empty string, but not null? What is the difference between 0 and null anyhow? And how can an empty string be a value?
kurt |
|
||||
|
Sounds like you need to use the function empty() if you're just trying to determine if a value has something useful in it, ie non zero or non empty string.
NULL effectively means that a value has never been set to anything. Setting a variable to zero or an empty string is therefore different to NULL because you deliberately set it to that value. This is an important distinction in programming. Some further explanation here: PHP: NULL - Manual |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Report post function | crankydave | WebProWorld: Guidelines/Announcements/Suggestions | 3 | 02-07-2006 05:10 PM |
| Form and Function | grease | Graphics & Design Discussion Forum | 0 | 09-19-2005 12:36 AM |
| Remember me function needed | trippleweb | WebProWorld: Guidelines/Announcements/Suggestions | 1 | 04-27-2005 02:50 PM |
| Why has this function used in that code? | abalfazl | Web Programming Discussion Forum | 2 | 03-11-2005 02:24 PM |
| PHP Function Calls via Links? | southplatte | Web Programming Discussion Forum | 4 | 07-27-2004 11:47 PM |
|
WebProWorld |
Advertise |
Contact Us |
About |
Forum Rules |
MVP's |
Archive |
Newsletter Archive |
Top |
WebProNews
WebProWorld is an iEntry, Inc. ® site - © 2009 All Rights Reserved Privacy Policy and Legal iEntry, Inc. 2549 Richmond Rd. Lexington KY, 40509 |