Reply to Re: [PHP] sql query

Your name:

Reply:


Posted by William Stokes on 03/02/05 20:25

OK got that. Thanks...


"Jason Petersen" <fuzzybad@gmail.com> kirjoitti
viestissδ:5eafe1ec0503020806886216f@mail.gmail.com...
> On Wed, 2 Mar 2005 13:02:39 +0200, William Stokes <kalles@operamail.com>
> wrote:
>> Hello
>>
>> Can someone explain this to me. I don't know how to read this.
>>
>> if (!$variable = mysql_query("select id,sessid from users where ...
>>
>> What is this "if(!"
>
> This is a way to run a SQL query, capture the return value, and
> perform an action if the query failed. For code readability, I would
> probably write that as two statements:
>
> $variable = mysql_query("SELECT * FROM blah");
> if(!$variable) { error_handler(mysql_error()); }
>
> See the documentation for information on mysql_query return values:
> http://us2.php.net/manual/en/function.mysql-query.php
>
> Jason

[Back to original message]


УдалСнная Ρ€Π°Π±ΠΎΡ‚Π° для программистов  •  Как Π·Π°Ρ€Π°Π±ΠΎΡ‚Π°Ρ‚ΡŒ Π½Π° Google AdSense  •  England, UK  •  ΡΡ‚Π°Ρ‚ΡŒΠΈ Π½Π° английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Π‘Π°ΠΉΡ‚ ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ Π² Π‘Ρ‚ΡƒΠ΄ΠΈΠΈ Π’Π°Π»Π΅Π½Ρ‚ΠΈΠ½Π° ΠŸΠ΅Ρ‚Ρ€ΡƒΡ‡Π΅ΠΊΠ°
ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ΠΈΠ΅ ΠΈ ΠΏΠΎΠ΄Π΄Π΅Ρ€ΠΆΠΊΠ° Π²Π΅Π±-сайтов, Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚ΠΊΠ° ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠ½ΠΎΠ³ΠΎ обСспСчСния, поисковая оптимизация