Home
Info
News
Crew
Links
  The Story
TV Series
OAV's
Movies
  Kenshin
Kaoru
Sanosuke
Yahiko
Megumi
Misao
Saitoh
Aoshi
Hiko

News

ceil($rtel)) { $pagina=1; } for ($i = 1; $i <= ceil($rtel); $i++) { if ($pagina == $i) $paginas[$i] = "$i"; else $paginas[$i] = "$i"; } $paginas= implode(" | ", $paginas); $vorige = ($pagina-1) ? "< Vorige" : ""; $volgende = ($pagina-ceil($rtel)) ? "Volgende >" : ""; if ($vorige && $volgende) { $navigatie = (" $vorige | $paginas | $volgende"); } else { $navigatie = (" $vorige | $paginas | $volgende"); } $query = mysql_query("SELECT * FROM nieuws ORDER BY id DESC LIMIT $van, $max"); while ($obj = mysql_fetch_object($query)){ $bericht = str_replace("", "
", $obj->bericht); $bericht = stripslashes($bericht); $nieuwsid = "$obj->id"; $rij = mysql_query("SELECT * FROM nieuwscomments WHERE nieuwsid=$nieuwsid"); $comments = mysql_num_rows($rij); if ($comments == "1") { $commentsnaam =" $comments comment"; } else { $commentsnaam =" $comments comments"; } if ($comments == "0") { $commentsnaam =" Post comment"; } ?>
$obj->datum"; ?>  Posted by $obj->naam"; ?>

$bericht"; ?>

["; ?> $commentsnaam"; ?> ]"; ?>

$navigatie
"); ?>
Images
Wallpapers
Winamp Skins
  Forum
Guestbook
Contact
Links
Post News
News Admin
 
"; } function foot () { echo "
"; } function record($REMOTE_ADDR) { include('configpoll.php'); $fp=fopen("$ip_file", "a+"); fputs ($fp,$REMOTE_ADDR."][".time()."\n"); fclose($fp); } function check($REMOTE_ADDR) { include('configpoll.php'); global $valid; $ip=$REMOTE_ADDR; $data=file("$ip_file"); $now=time(); foreach ($data as $record) { $subdata=explode("][",$record); if ($now < ($subdata[1]+3600*$timeout)) { if ($ip == $subdata[0]) { $valid=0; break; }}}} //##################### Save data ############################## function save($answer){ global $answer; include('configpoll.php'); $data=file($datafile); $subdata=explode("][",$data[$answer]); $subdata[2]+=1; $data[$answer]=implode("][", $subdata); $data[$answer]=$data[$answer]."\n"; $fp=fopen($datafile,"w+"); $a=0; do{ fputs($fp,$data[$a]); $a++; }while($a

"; $data=file($datafile); $question=$data[0]; $nb_options=count($data)-1; echo "$question

"; for($nb=1;$nb <= $nb_options; $nb++){ $option=explode("][","$data[$nb]"); echo " "; echo "$option[0]
"; } echo ""; echo "

"; echo "
Results

"; foot(); } //################## Function to show results ######################## function results(){ include('configpoll.php'); head(); $data=file($datafile); $nb_answers=count($data); $votes=0; $a=1; do{ $subdata=explode("][",$data[$a]); $votes += $subdata[2]; $a++; }while($a < $nb_answers); $a=1; $b="answerv"; $v=100/$votes; echo "

$data[0] ($votes v.)

"; do{ $subdata=explode("][",$data[$a]); $av = $subdata[2] * $v; echo "$subdata[0] -"; printf(" %01.1f", $av); echo"%
"; $p2v = 100-$av; echo "
"; $a++; } while ($a < $nb_answers); echo "
"; foot(); } //###################### Engine #################################### check($REMOTE_ADDR); if ($valid=="0"){ results();} elseif ($action=="results") { results(); } elseif ($save=="yes" && $valid!="0") { save($Answer); record($REMOTE_ADDR); results();} elseif ($action=="save" && !empty($valid)) { results(); } elseif ($action!="save" && $valid!="0"){ form($PHP_SELF); } ?>
\n"); $aantal = count($Bezoeker); for ($tel = 0; $tel < $aantal; $tel++){ $DeBezoeker = $Bezoeker[$tel]; $DeBezoeker[0] = $DeBezoeker[0] + $tijdmax; if ($DeBezoeker[0] > $tijdnu) fputs($file, "\n"); } fclose($file); } $Bezoeker = ""; // Opslaan van de bezoeker include ("data.php"); $aantal = count($Bezoeker); for ($tel = 0; $tel < $aantal; $tel++){ $DeBezoeker = $Bezoeker[$tel]; if ($DeBezoeker[1] == $ipadres) $opslaan = "nee"; } if (!$opslaan){ $file = fopen("data.php","a"); fputs($file, "\n"); fclose($file); } // Laten zien van de bezoekers $Bezoeker = ""; include ("data.php"); $aantal = count($Bezoeker); for ($tel = 0; $tel < $aantal; $tel++){ $DeBezoeker = $Bezoeker[$tel]; $DeBezoeker[0] = $DeBezoeker[0] + $tijdmax; if ($DeBezoeker[0] > $tijdnu) $online = $online + 1; } // Printen if (!$online) $online = 1; if ($online == 1) print ("There is 1 visitor on this site."); else print ("There are now $online visitors on this site."); ?>

<plaintext>