Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [MySQL][PHP]Dosc glupi problem
Raven1122
post
Post #1





Grupa: Zarejestrowani
Postów: 369
Pomógł: 2
Dołączył: 1.11.2010

Ostrzeżenie: (0%)
-----


Witam, mam 2 funkcje:
  1. function getsettings(){
  2. $sql = "SELECT * FROM arena_settings";
  3. $query = mysql_query($sql);
  4. $setting = mysql_fetch_array($query);
  5. }


Pobiera ustawienia i w 2 funkcji robie takie cos:

  1. connect();
  2. getsettings();
  3. //Ilosc wiadomosci w bazie:
  4. $sql = "SELECT * FROM arena_news";
  5. $query = mysql_query($sql) or die(mysql_error());
  6. $newsow = mysql_num_rows($query);
  7. //Ustawienia pagera
  8. $ile = $setting['displaynews'];


No i wyskakuje mi taki blad:
You 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

Moze ktos pomoc?
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 23.08.2025 - 19:29