Buyrun bu da fikstür için.
<?php
/**
* Süper Lig Fikstür
* @author Gökhan YILDIZ - http://www.gokhan-yildiz.com
*/
function get($first, $last, $text)
{
@preg_match_all('/' . preg_quote($first, '/') .
'(.*?)'. preg_quote($last, '/').'/i', $text, $m);
return @$m[1];
}
$status =strip_tags(htmlspecialchars(trim($_GET["week"])));
// Get Content
if($status=="this"){
$url = "http://skorer.milliyet.com.tr/Fikstur?TTName=";}
elseif($status=="next") {
$url = "http://skorer.milliyet.com.tr/Fikstur?TTName=&RW=1";}
elseif($status=="last") {
$url = "http://skorer.milliyet.com.tr/Fikstur?TTName=&RW=-1";}
elseif($status==""){
$url = "http://skorer.milliyet.com.tr/Fikstur?TTName=";
}
$content = file_get_contents($url);
$get_date = get('class="date">', '</td>', $content);
$get_hour = get('class="hour">', '</td>', $content);
$get_team1 = get('class="team team1">', '</td>', $content);
$get_score = get('class="sonuc">', '</td>', $content);
$get_team2 = get('class="team team2">', '</td>', $content);
$get_count = count($get_date) - 1;
//Superlig Puan Durumu
echo '
<a href="fixture.php?week=last">Geçen Hafta</a> | <a href="fixture.php?week=this">Bu Hafta</a> | <a href="fixture.php?week=next">Gelecek Hafta</a>
';
if($status=="this"){echo "<h4>Süper Lig'de Bu Hafta</h4>";}
elseif($status=="next"){echo "<h4>Süper Lig'de Gelecek Hafta</h4>";}
elseif($status=="last"){echo "<h4>Süper Lig'de Geçen Hafta</h4>";}
elseif($status==""){echo "<h4>Süper Lig'de Bu Hafta</h4>";}
echo'
<table width="560px" border="1" cellpadding="0" cellspacing="0" style="border:1px dotted #ccc;">
<tr style="background-color:#000; color:#fff; font-weight:bold;">
<td style="width:120px;">Tarih</td>
<td style="width:50px;">Saat</td>
<td style="width:220px;">Ev Sahibi</td>
<td style="width:50px;">Skor</td>
<td style="width:220px;">Misafir Takım</td>
</tr>
';
for ($i=0; $i<=$get_count; $i++) {
echo '
<tr>
<td>'.$get_date[$i].'</td>
<td>'.$get_hour[$i].'</td>
<td>'.$get_team1[$i].'</td>
<td>'.strip_tags($get_score[$i]).'</td>
<td>'.$get_team2[$i].'</td>
</tr>
';
}
echo '</table>';
?>Demo:
http://gokhan-yildiz.com/fixture.php