millers Posted April 24, 2008 Report Share Posted April 24, 2008 sveicinati man ir jautajums ka var dabuti lai sis kods strada ???? es nez kur vaina moska nemaku pareizi mysql colum uztaisiit ja varat palidzat rekur viss code ... http://paste.php.lv/7240 Link to comment Share on other sites More sharing options...
andrisp Posted April 25, 2008 Report Share Posted April 25, 2008 Varbūt tomēr izstāsti, kas tur nenotiek ? Link to comment Share on other sites More sharing options...
anonīms Posted April 25, 2008 Report Share Posted April 25, 2008 Ja pareizu sapratu, tad viņam nesadalās vairākās lapās. if(!isset($_GET['lapa'])){ $lapa = 1; } else { $lapa = $_GET['lapa']; } $max_results = 30; $from = (($lapa * $max_results) - $max_results); $sql = mysql_query("SELECT * FROM cw_rezultati ORDER BY id DESC LIMIT $from, $max_results"); $total_results = mysql_result(mysql_query("SELECT COUNT(*) as Num FROM cw_rezultati"),0); $total_pages = ceil($total_results / $max_results); echo "".$lang['lapa'].": "; if($lapa > 1){ $prev = ($lapa - 1); echo "<a href=\"".$_SERVER['PHP_SELF']."?lapa=$prev\"></a> "; } for($i = 1; $i <= $total_pages; $i++){ if(($lapa) == $i){ echo "$i "; } else { echo "<a href=\"".$_SERVER['PHP_SELF']."?lapa=$i\"><b>$i</b></a> "; } } if($lapa < $total_pages){ $next = ($lapa + 1); echo "<a href=\"".$_SERVER['PHP_SELF']."?lapa=$next\"></a>"; } Link to comment Share on other sites More sharing options...
millers Posted April 26, 2008 Author Report Share Posted April 26, 2008 anonims a kads code man ieksa tani table ir jarakstA? Link to comment Share on other sites More sharing options...
anonīms Posted April 26, 2008 Report Share Posted April 26, 2008 kas par table? :\ <table> <?php while($row = mysql_fetch_array($sql)) { echo "$yyoo"; } Link to comment Share on other sites More sharing options...
millers Posted April 26, 2008 Author Report Share Posted April 26, 2008 nu mysql table Link to comment Share on other sites More sharing options...
p4F Posted April 26, 2008 Report Share Posted April 26, 2008 http://paste.php.lv/7247?lang=php Link to comment Share on other sites More sharing options...
millers Posted April 27, 2008 Author Report Share Posted April 27, 2008 a kada man datubaze ieksa mysql jauztaisa ? un ieksa datubazes kadas tabulas? Link to comment Share on other sites More sharing options...
werd Posted April 27, 2008 Report Share Posted April 27, 2008 (edited) a kada man datubaze ieksa mysql jauztaisa ? un ieksa datubazes kadas tabulas? A kam par godu ieliki šo linku ja pats rakstīji kodu, tad tākā jāzin ko raksti Tur tev pašam norādīts SELECT id FROM tbl_name tbl_name ir tās tabulas nosaukums Edited April 27, 2008 by phpjanis Link to comment Share on other sites More sharing options...
millers Posted April 28, 2008 Author Report Share Posted April 28, 2008 sito code pats netaisiju tapec ari jataju ja bet kas ieksa table jaraksta lai stradatu viss ka nakas? Link to comment Share on other sites More sharing options...
Recommended Posts