could not be converted to string - Visavi.net https://visavi.net/ RSS - Visavi.net https://visavi.net/assets/img/images/logo_small.png RSS - Visavi.net https://visavi.net/ [email protected] (admin) [email protected] (admin) Sun, 30 Jun 2024 11:04:43 +0300 В гугле ничего не нашел, возможно плохо искал. Спасибо всем. К сожалению, не могу изменять авторитет. https://visavi.net/topics/29774/514743 could not be converted to string Мага Sun, 26 Feb 2012 22:30:51 +0400 Сообщения https://visavi.net/topics/29774/514743 неужели так трудно загулить?<br> while ($stmt-&gt;fetch()) {<br> echo $fio;<br> } https://visavi.net/topics/29774/514646 could not be converted to string Александр Sun, 26 Feb 2012 21:19:15 +0400 Сообщения https://visavi.net/topics/29774/514646 Жду ответа https://visavi.net/topics/29774/514623 could not be converted to string Мага Sun, 26 Feb 2012 20:58:12 +0400 Сообщения https://visavi.net/topics/29774/514623 Все равно только одну строку выводит... https://visavi.net/topics/29774/514399 could not be converted to string Мага Sun, 26 Feb 2012 15:03:26 +0400 Сообщения https://visavi.net/topics/29774/514399 ORDER BY id ASC сверху внизу, ORDER BY id DESC снизу вверх https://visavi.net/topics/29774/514391 could not be converted to string TRAIL Sun, 26 Feb 2012 14:44:53 +0400 Сообщения https://visavi.net/topics/29774/514391 <pre class="prettyprint"> &lt;? $load = new mysqli(&quot;localhost&quot;,&quot;req&quot;,&quot;maga94&quot;,&quot;req&quot;); $stmt = $load-&gt;prepare(&quot;SELECT * FROM NOTVIEWED ORDER BY `ID`&quot;); $stmt-&gt;execute(); $stmt-&gt;bind_result($id, $login, $pass, $fio, $bdate, $pasport, $pdate, $podr, $adr, $job, $jadr, $vklad, $comp, $year, $opyt, $sport, $tel, $mail, $nam, $desc, $status); $stmt-&gt;fetch(); echo $fio; ?&gt; </pre> выводит только одну строку из базы... https://visavi.net/topics/29774/514388 could not be converted to string Мага Sun, 26 Feb 2012 14:34:22 +0400 Сообщения https://visavi.net/topics/29774/514388 Очень надеюсь на вашу помощь. https://visavi.net/topics/29774/514331 could not be converted to string Мага Sun, 26 Feb 2012 10:07:02 +0400 Сообщения https://visavi.net/topics/29774/514331 Разобрался. Подскажите, как вывести строки из базы по убыванию поля ID? Т.е. с последних записей. https://visavi.net/topics/29774/513242 could not be converted to string Мага Sat, 25 Feb 2012 10:24:51 +0400 Сообщения https://visavi.net/topics/29774/513242 <pre class="prettyprint"> &lt;? $stmt = $load-&gt;query(&quot;SELECT MAX(`ID`) FROM NOTVIEWED&quot;); ?&gt; </pre> Выводит Catchable fatal error: Object of class mysqli_result could not be converted to string, может мне кто-нибудь объяснить, почему? Вроде должен выводить максимальное значение поля ID... https://visavi.net/topics/29774/513234 could not be converted to string Мага Sat, 25 Feb 2012 10:13:09 +0400 Сообщения https://visavi.net/topics/29774/513234 Все ясно, спасибо. https://visavi.net/topics/29774/512856 could not be converted to string Мага Fri, 24 Feb 2012 20:35:38 +0400 Сообщения https://visavi.net/topics/29774/512856 тогда printf($stmt-&gt;error); https://visavi.net/topics/29774/512848 could not be converted to string Александр Fri, 24 Feb 2012 20:19:59 +0400 Сообщения https://visavi.net/topics/29774/512848 Fatal error: Call to undefined method mysqli_stmt::errorInfo() https://visavi.net/topics/29774/512834 could not be converted to string Мага Fri, 24 Feb 2012 20:03:48 +0400 Сообщения https://visavi.net/topics/29774/512834 в конце кода print_r($stmt-&gt;errorInfo()); https://visavi.net/topics/29774/512826 could not be converted to string Александр Fri, 24 Feb 2012 19:54:39 +0400 Сообщения https://visavi.net/topics/29774/512826 Жду ответа... https://visavi.net/topics/29774/512788 could not be converted to string Мага Fri, 24 Feb 2012 18:31:45 +0400 Сообщения https://visavi.net/topics/29774/512788 Действительно, дело оказалось в char, более 255 не поддерживается, спасибо. Другая проблема, код ниже не хочет записывать в базу<br> <pre class="prettyprint"> &lt;? $stmt = $load-&gt;prepare(&quot;INSERT INTO NOTVIEWED (LOGIN, PASS, FIO, BDATE, PASPORT, PDATE, PODR, ADR, JOB, JADR, VKLAD, COMP, 5YEAR, OPYT, SPORT, TEL, MAIL, NAME, DESCRIPT) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)&quot;); $stmt-&gt;bind_param(&#039;sssssssssssssssssss&#039;, $login, $pass, $fio, $bdate, $pasport, $pdate, $podr, $adr, $job, $jadr, $vklad, $comp, $year, $opyt, $sport, $tel, $mail, $name, $desc); $login=$_POST&#91;&#039;login&#039;]; $pass=$_POST&#91;&#039;pass&#039;]; $fio=$_POST&#91;&#039;fio&#039;]; $bdate=$_POST&#91;&#039;bdate&#039;]; $pasport=$_POST&#91;&#039;pasport&#039;]; $pdate=$_POST&#91;&#039;pdate&#039;]; $podr=$_POST&#91;&#039;podr&#039;]; $adr=$_POST&#91;&#039;adr&#039;]; $job=$_POST&#91;&#039;job&#039;]; $jadr=$_POST&#91;&#039;jadr&#039;]; $vklad=$_POST&#91;&#039;vklad&#039;]; $comp=$_POST&#91;&#039;comp&#039;]; $year=$_POST&#91;&#039;5year&#039;]; $opyt=$_POST&#91;&#039;opyt&#039;]; $sport=$_POST&#91;&#039;sport&#039;]; $tel=$_POST&#91;&#039;tel&#039;]; $mail=$_POST&#91;&#039;mail&#039;]; $nam=$_POST&#91;&#039;nam&#039;]; $desc=$_POST&#91;&#039;desc&#039;]; echo $fio; $stmt-&gt;execute(); ?&gt; </pre> https://visavi.net/topics/29774/512159 could not be converted to string Мага Thu, 23 Feb 2012 22:11:59 +0400 Сообщения https://visavi.net/topics/29774/512159