B              L              O              G              M              A              N

Technics SU-V45A Technics SU-V45A Technics SU-V45A Technics SU-V45A Technics SU-V45A Technics SU-V45A Technics SU-V45A BLOGMAN random image 16

Jaja, ook de bijdragen worden automagisch geteld !

28 maart 2008, 23:22:45 geplaatst door Blogman · 5 Reacties · Ontwikkeling, Stand

post_title, 0, 1) == “#”) {
$uitslagposttitle = substr($list->post_title, 1, 3);
if($uitslagposttitle > $beginwaarde and $uitslagposttitle < $eindwaarde) { // $postidarray[$uitslagposttitle] = $list->ID; // echo $uitslagposttitle; echo “
“;
$postauthorarray[$uitslagposttitle] = $list->post_author; // echo $uitslagposttitle; echo “
“;
//$arrayteller++;
}
}
}

$authorarrayteller = “0”;
$authorselect = “select * from wp_users”;
$authorquery = mysql_query($authorselect);
$authorrecords = mysql_num_rows($authorquery);
while ($authorlist = mysql_fetch_object($authorquery)) {
$author = $authorlist->display_name;
$authorid[$author] = $authorlist->ID;
//echo $authorid[$author]; echo $author; echo “
“;
}

$bijdragenarray = array();
$aantalid = count($postauthorarray);
//echo $aantalid;
$aantalauthor = count($authorid);
foreach ($authorid as $auteur => $auteurnummer) {
// echo $auteur; echo “
“;
//$bijdragenarray[$auteur] = “0”;
foreach ($postauthorarray as $postnummer => $auteurnummer2) {
if ($auteurnummer == $auteurnummer2) {
$bijdragenarray[$auteur]++;
// echo $postnummer; echo $auteurnummer2; echo “
“;
}
}
// echo $bijdragenarray[$auteur]; echo “
“;
}

if(isset($bijdragenarray)) {
arsort($bijdragenarray);
}

echo “

“;

$totaalaantal = “0”;
$teller = “0”;
foreach ($bijdragenarray as $label => $inhoud) {
$teller++;
$naamarray[$teller] = ucfirst($label);
$scorearray[$teller] = $inhoud;
if ($teller == 1) {
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

“;
echo “

$teller.    $naamarray[$teller] “;
} else {
if ($scorearray[$teller] == $scorearray[$teller-1]) {
echo “, $naamarray[$teller] “;
} else {
echo ”  
“;
echo $scorearray[$teller-1];
echo “
“;
echo $teller;
echo “.   
$naamarray[$teller] “;
}
}
}
echo ”  
“;
echo $scorearray[$teller];
echo “

“;

//echo “Totaal $aantalposts punten”;

?>

Met nog wat kleine bugs en natuurlijk nog niet alle hoezen geplaatst !

Tags:

5 reacties tot nog toe ↓

  • 1 Pieter // 29 maart 2008 om 10:34:51

    Magisch…

  • 2 Blogman // 29 maart 2008 om 11:47:07

    Bij de stand staan nu ook 2 nieuwe lijstjes: 2-100 en 101-200. Maar ‘s een widget gaan bouwen..

  • 3 Pieter // 29 maart 2008 om 12:01:18

    En daarna iets bouwen wat automatisch die hoezen raadt. Wel zo handig.

  • 4 Blogman // 29 maart 2008 om 12:08:46

    Haha ! 🙂

  • 5 Blogman // 29 maart 2008 om 13:43:40

    Ik ga voetballen. Mazzel.

You must log in om een reactie achter te laten.