Displaying WML over multiple cards from MYSQL -Please help
The line at the bottom <<<....">....>>> the $pagenext phrase will not work. I can get similar PHP to work in HDML and HTML. I just can't figure out what's wrong. Any help would be greatly appreciated!Thanks.Bill billy.wilson@rogers.com
<?php
$connection = mysql_connect("localhost",
"XXXXX", "XXXXXX"or die ("Couldn't connect to database"
$db = mysql_select_db("a0012290" or die ("Couldn't select DB"
$limit = 5;
$sqlcount= "SELECT ROWA, ROWB, City FROM EXAMPLETABLE WHERE City='$city' ORDER BY ROWA";
$sql_countresult = mysql_query($sqlcount, $connection) or die ("Couldn't execute query"
$totalrows = mysql_num_rows($sql_countresult);
if(empty($page)){
$page = 1;
}
$limitvalue1 = $page*$limit-($limit);
$sql = "SELECT ROWA, ROWB, City FROM EXAMPLETABLE WHERE City='$city' ORDER BY ROWA LIMIT $limitvalue1, $limit";
$sql_result = mysql_query($sql, $connection) or die ("Couldn't execute query"
if(($totalrows-($limit*$page)) > 0){
$pagenext = $page+1;
echo "<do type=\"accept\" label=\"more\" name=\"more\"><go href=\"EXAMPLE.php?city=$city&page=$pagenext\"></go></do>"; // if the totalrows - $limit * $page is > 0 (meaning there is a remainder), leave the next button.
}