Am busy recoding it now, will post in a bit.
What is thet $m_ct = 0; for? i see no use in it?
and
if ($row['id'] || $track["$tracker"])
is a problem because "||" is a logical OR, it should have been "!=" which is the NOT EQUAL TO shortform for that equation
EDIT:
<?php
$limit = '4';
$m_ct = '0';
$track = array();
for ($count = 0; $count < $limit; $count++)
{
$ct = mt_rand(1, 5);
if ($count < 4)
{
$result = mysql_query("SELECT menucon_$ct,id FROM sfb_pages WHERE adstack_accpt_$ct ='y'");
while ($row = mysql_fetch_array($result))
{
$trackit = $row['id'];
if ($row['id'] != array_keys($track))
{
echo htmlspecialchars_decode($row["menucon_$ct"]) . "</br></br>";
$track[] = $trackit;
}
}
}
}
?>
Try this and see if that solves the problem?
NOTE TO ADMIN:
Having problems replying in this topic, saying the reply file is unavailable.