Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [MySQL][PHP] random a rekordy z bazy
Lethys
post
Post #1





Grupa: Zarejestrowani
Postów: 642
Pomógł: 2
Dołączył: 9.03.2006

Ostrzeżenie: (30%)
XX---


mam taki prosty kod:

  1.  
  2. $stat = mysql_fetch_array(mysql_query("select * from players where user='$user' and pass='$haslo'"));
  3.  
  4. $poltora = $stat[lvl]*1,5;
  5. $poltora2 = $poltora + rand(1,5);
  6. $koniec = $stat[lvl]*2,5 + rand(1,5);
  7.  
  8. $dmin = rand($stat[lvl],$poltora);
  9. $dmax = rand($poltora2,$koniec);


Zamiast działania jest biała strona. Podejrzewam, że problem jest gdzieś w zapisie. Ale kombinuje, kombinuje i nic (IMG:style_emoticons/default/sad.gif)

EDIT. juz działa, zamiast przecinków trzeba było kropki wstawić. Sorry za fatyge (IMG:style_emoticons/default/tongue.gif)

Ten post edytował Lethys 23.04.2011, 12:25:32
Go to the top of the page
+Quote Post

Posty w temacie
- Lethys   [MySQL][PHP] random a rekordy z bazy   23.04.2011, 12:24:14


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 - 00:51