Blitz Posted October 17, 2006 Report Share Posted October 17, 2006 (edited) Bus vien jataisa parbaude, kur jaskatas vai tada ip jau nav tabulaa. $res=mysql_query("SELECT ip FROM person WHERE ip='$_POST[ip]' ") if ($mysql_num_rows($res)>0) { //ahaa ir jau tabulaa } else { //ieraksti tabulaa ar savu to kodu } Edited October 17, 2006 by Blitz Link to comment Share on other sites More sharing options...
saprotiet mani Posted October 17, 2006 Author Report Share Posted October 17, 2006 paldies blitz. :) es tagad čakarējos ar to un es cik nopratu man tas kods ir jāliek insert.php itkā skatijos, kur pēc manām domām viss loģiskāk ieietu tas tavs kods. ieliku to un reku šeku tas ir bet man rāda ka 12 līnijā ir Parse error, īsti nesaprotu ko tas nozīmē, lēnām visu mācos, tadeļ lūdzu palidzi man, varbūt vari parādīt, kur labāk iemest to tavu kodu? Link to comment Share on other sites More sharing options...
andrisp Posted October 17, 2006 Report Share Posted October 17, 2006 Tev Blitz pareizi iedeva, un tu vienalga nepareizi pārakstīji? nu vispār.. Jābūt: if (expression) { } Link to comment Share on other sites More sharing options...
saprotiet mani Posted October 18, 2006 Author Report Share Posted October 18, 2006 Nevajag taisīt muļķīgas QUOTEs (bubu) Tas jāmet 12 rindiņā? Bāāc.. es nevaru iebraukt kur tad īsti jāmet tas blitz kods... :/ Link to comment Share on other sites More sharing options...
andrisp Posted October 18, 2006 Report Share Posted October 18, 2006 Nu sintakse tev nav pareiza! Kā tu domāk kā ir pareizi ? if bla == ble {} ? vai if (bla == bla) {} ? Link to comment Share on other sites More sharing options...
saprotiet mani Posted October 18, 2006 Author Report Share Posted October 18, 2006 Nevajag taisīt muļķīgas QUOTEs (bubu) nu 2 variants, bet kur tad isti jamet tas tavs if (expression) ? Link to comment Share on other sites More sharing options...
andrisp Posted October 18, 2006 Report Share Posted October 18, 2006 Nekur nav jāmet - izlabo savu skriptu http://paste.php.lv/4573. Link to comment Share on other sites More sharing options...
Recommended Posts