Welcome Guest, Not a member yet? Register   Sign In
This empty string won't insert in my database
#5

[eluser]jpcody[/eluser]
jtkendall, brilliant! Thanks so much!

So essentially it's not NULL because there's an object there, the object just happens to be empty? And it only returns an empty object if there is no in_reply_to_user_id value set? Otherwise it returns a string? Er, string of integers?

Tiny necessary parenthesees-location modification for posterity's sake:

$reply = (is_null($t->in_reply_to_user_id) || is_object($t->in_reply_to_user_id) ? 'NULL' : $t->in_reply_to_user_id);


Messages In This Thread
This empty string won't insert in my database - by El Forum - 12-06-2009, 12:08 PM
This empty string won't insert in my database - by El Forum - 12-06-2009, 03:32 PM
This empty string won't insert in my database - by El Forum - 12-06-2009, 03:35 PM
This empty string won't insert in my database - by El Forum - 12-06-2009, 04:07 PM
This empty string won't insert in my database - by El Forum - 12-06-2009, 04:32 PM



Theme © iAndrew 2016 - Forum software by © MyBB