Why's my reverse_array() not working?
Posted: Sun Feb 20, 2005 8:37 pm
Im using this:
But for some reason its not showing the 4th to last, 3rd to last or the 2nd to last line of the document hum.php. Its just showing a blank space... why?
Code: Select all
*snip*
$statsї'url'] = "$mybb_forumurl";
$lines = @file("".$statsї'url']."hum.php");
if(!$lines) {
if(!$statsї'posts'] || !$statsї'threads'] || !$statsї'members']) {
echo "<td colspan="3" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1" color="#FF0000"><b>Cannot Find Stats For:<br>$statsїurl]<br><a href="".$statsї'url']."stats.php" target="_blank">View External Stats.</a></b></font></td>";
} else {
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">".$statsї'posts']."</td>";
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">".$statsї'threads']."</td>";
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">".$statsї'members']."</td>";
}
} else {
foreach ($lines as $line_num => $line) {
$input = array(htmlspecialchars($line));
$arrї] = array_reverse($input);
}
$html = implode('', $lines);
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">$arrї4]</font></td>";
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">$arrї3]</font></td>";
echo "<td width="4%" bgcolor="#FFFFFF" nowrap><font face="Tahoma" size="1">$arrї2]</font></td>";
}
*snip*