include ("../include/includes.inc");
if (($REQUEST_METHOD=='POST')) {
for(reset($HTTP_POST_VARS);
$key=key($HTTP_POST_VARS);
next($HTTP_POST_VARS)) {
$var = addslashes($HTTP_POST_VARS[$key]);
$var = stripslashes($var);
$var = strtr($var, "|", " ");
$$key = $var;
}
}
$title='Lore';
require ("../include/header.php");
$skip or $skip = 0;
$curr = 1;
connect_db();
$select = "select * from lore where public = 'y'";
$result = mysql_query($select) or die("Select Failed!");
$num_lore = mysql_num_rows($result);
?>
Description |
author |
$start = $skip;
$end = ($skip +20 > $num_lore)?$num_lore: ($skip +20);
while ($lore = mysql_fetch_array($result)){
if (($start < $curr) && ($curr <= $end)) {
$id = $lore['lore_id'];
$author = get_user_name($lore['member_id']);
?>
echo $lore['name']; ?> |
echo $author; ?> |
}
$curr++;
} ?>
if (($num_lore - $skip) >= 20){ ?>
Back 20 lore
} else { ?>
Back 0 lore
}?>
|
echo "$start - $end / $num_lore"; ?>
|
if ($skip){
if ($skip >= 20){
?>
Forward 20 lore
}else {
?>
Forward lore
}} else {?>
Forward 0 lore
}?>
|
require ("../include/footer.html");
?>