Guest User

Untitled

a guest
Feb 18th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. <?php
  2. include("../knhbSpider.php");
  3. $spider = new knhbSpider;
  4. $spider->mysqlHost = "localhost";
  5. $spider->mysql_user = "xxxx";
  6. $spider->mysql_db = "xxxx";
  7. $spider->mysql_password = "xxxx";
  8.  
  9. $club_id = mysql_escape_string($_GET['club_id']);
  10. $team_name = mysql_escape_string($_GET['team']);
  11. $results = $spider->lookupResultsForTeam($club_id,$team_name);
  12. ?>
  13.  
  14. <h1><?=$results[0][club_name] . " " . $results[0][team1];?></h1>
  15. <?
  16. if (is_array($results)) {
  17. foreach ($results as $result) {
  18. $match_type_string = "";
  19. if($result[match_type] == 2) $match_type_string = "(Zaal wedstrijd) ";
  20. ?>
  21. <p>
  22. <?
  23. echo ($result[out])? "Uit" : "Thuis";
  24. echo " ".$result['club_name2'];
  25. echo " ".$result[team2];
  26. ?>
  27. </p>
  28. <p><?echo $match_type_string;?></p>
  29. <p><? echo date("d-m-Y",$result[date]);?></p>
  30. <p>Resultaat: <? echo $result[goals1] . " - " . $result[goals2];?></p>
  31. <?
  32. }} else {
  33. ?>
  34. <p>Er zijn geen uitslagen voor dit team gevonden in de database.</p>
  35. <?
  36. }
  37. ?>
Add Comment
Please, Sign In to add comment