<tr> <td class="next">'; echo '<select name="art"> $query = "SELECT * FROM $teksty_art_tbl ORDER BY imie_nazwisko"; $result = mysql_query($query); while($r = mysql_fetch_array($result)) { $id = $r['id']; $name = $r['imie_nazwisko']; } echo '</select>'; echo '</td> </tr> <tr> <td> <input type="text" name="art_other" size="35"> </td> </tr>
a funkcja dodajaca do bazy te dane jest taka:
<?php function add_send() { if($itype=='list') { $sql = mysql_query("INSERT INTO $teksty_music_tbl VALUES (NULL, '$title', '$art', '$nick', '', '$text', now(), '-'"); } elseif($itype=='other') { $sql = mysql_query("INSERT INTO $teksty_music_tbl VALUES (NULL, '$title', '$art_other', '$nick', '', '$text', now(), '-'"); } else { } } ?>
i prubując dodac cos wywala taki błąd:
Cytat
Pomy�lnie dodano twoj text do bazy, musisz poczekac az admin go zaakceptuje LISTAYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
według mnie niema słow zastrzeżonych przez MySQL.... ale moge się mylić...