Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Kodas..
Parašė dalampacki· 2011 Sau. 5 14:01:53
#1
Sveiki, iškilo man tokia problemėle manr reiktų į šitą panelę
opentable("Naujausia Muzika ");
$top = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_datestamp DESC LIMIT 0,20");
echo "<a name='top' id='top'></a>";
echo "<table cellspacing='0' cellpanding='0' width='100%' align='center'><tr><td class='cell'><strong>Nr.</strong></td><td class='cell'><strong>Pavadinimas</strong></td><td class='cell'><strong>Idėta</strong></td><td class='cell'><strong>Siuntesi</strong></td><td class='cell' width='5'> <strong> Pateikė</strong></td></tr>";
$a = 1;
while($data = dbarray($top)){
$result = dbquery("SELECT user_id FROM ".$db_prefix."users WHERE user_name='".$data['download_license']."'");
$data2 = dbarray($result);
echo "<tr><td valign='top' class='cell'>$a.</td><td valign='top' class='cell'><a href='".seoname($data['download_title']."-ids".$data['download_id']).".html' title='Parsisiusti' class='side'>".$data['download_title']."</a></td><td class='cell'>".showdate("%Y.%m.%d", $data['download_datestamp'])."</td><td class='cell' align='center'>".$data['download_count']."</td><td class='cell' align='center'><a href='".seoname($data['download_license'])."-uid".$data2['user_id'].".html'>".$data['download_license']."</a></td></tr>";
$a++;
}
echo "</table>";
closetable();
Įdėti šitą kodą:
if ($data['super'] == 1) {
echo"<font color='red'><b>Super!</b></font>";
}
Tą kodą reikia dėti ten kur atvaizduojama dainos pavadinimas bet ne prieš dainos pavadinimą o po.
Parašė Wasiulis· 2011 Sau. 5 14:01:13
#2
opentable("Naujausia Muzika ");
$top = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_datestamp DESC LIMIT 0,20");
echo "<a name='top' id='top'></a>";
echo "<table cellspacing='0' cellpanding='0' width='100%' align='center'><tr><td class='cell'><strong>Nr.</strong></td><td class='cell'><strong>Pavadinimas</strong></td><td class='cell'><strong>Idėta</strong></td><td class='cell'><strong>Siuntesi</strong></td><td class='cell' width='5'> <strong> Pateikė</strong></td></tr>";
$a = 1;
while($data = dbarray($top)){
$result = dbquery("SELECT user_id FROM ".$db_prefix."users WHERE user_name='".$data['download_license']."'");
$data2 = dbarray($result);
if ($data['super'] == 1) {
echo"<font color='red'><b>Super!</b></font>";
} else {
echo "";
}
echo "<tr><td valign='top' class='cell'>$a.</td><td valign='top' class='cell'><a href='".seoname($data['download_title']."-ids".$data['download_id']).".html' title='Parsisiusti' class='side'>".$data['download_title']."</a>".$data['super']."</td><td class='cell'>".showdate("%Y.%m.%d", $data['download_datestamp'])."</td><td class='cell' align='center'>".$data['download_count']."</td><td class='cell' align='center'><a href='".seoname($data['download_license'])."-uid".$data2['user_id'].".html'>".$data['download_license']."</a></td></tr>";
$a++;
}
echo "</table>";
closetable();
Redagavo Wasiulis· 2011 Sau. 5 14:01:19
Parašė dalampacki· 2011 Sau. 5 15:01:59
#3
Vasiulis, neveikia ;/ o kai prieš dainą padarai tai viskas normaliai veikia.
Parašė Wasiulis· 2011 Sau. 5 16:01:31
#4
Pabandyk taip.
opentable("Naujausia Muzika ");
$top = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_datestamp DESC LIMIT 0,20");
echo "<a name='top' id='top'></a>";
echo "<table cellspacing='0' cellpanding='0' width='100%' align='center'><tr><td class='cell'><strong>Nr.</strong></td><td class='cell'><strong>Pavadinimas</strong></td><td class='cell'><strong>Idėta</strong></td><td class='cell'><strong>Siuntesi</strong></td><td class='cell' width='5'> <strong> Pateikė</strong></td></tr>";
$a = 1;
while($data = dbarray($top)){
$result = dbquery("SELECT user_id FROM ".$db_prefix."users WHERE user_name='".$data['download_license']."'");
$data2 = dbarray($result);
if ($data['super'] == 1) {
$top = "<font color='red'><b>Super!</b></font>";
} else {
$top = "";
}
echo "<tr><td valign='top' class='cell'>$a.</td><td valign='top' class='cell'><a href='".seoname($data['download_title']."-ids".$data['download_id']).".html' title='Parsisiusti' class='side'>".$data['download_title']."</a>$top</td><td class='cell'>".showdate("%Y.%m.%d", $data['download_datestamp'])."</td><td class='cell' align='center'>".$data['download_count']."</td><td class='cell' align='center'><a href='".seoname($data['download_license'])."-uid".$data2['user_id'].".html'>".$data['download_license']."</a></td></tr>";
$a++;
}
echo "</table>";
closetable();
Parašė dalampacki· 2011 Sau. 5 16:01:24
#5
Nu dabar rodo, bet tik vieną dainą; / o turi rodyt 20
Redagavo dalampacki· 2011 Sau. 5 16:01:09
Parašė Wasiulis· 2011 Sau. 5 16:01:16
#6
:D mano klaida, ištaisiau.
opentable("Naujausia Muzika ");
$top = dbquery("SELECT * FROM ".$db_prefix."downloads ORDER BY download_datestamp DESC LIMIT 0,20");
echo "<a name='top' id='top'></a>";
echo "<table cellspacing='0' cellpanding='0' width='100%' align='center'><tr><td class='cell'><strong>Nr.</strong></td><td class='cell'><strong>Pavadinimas</strong></td><td class='cell'><strong>Idėta</strong></td><td class='cell'><strong>Siuntesi</strong></td><td class='cell' width='5'> <strong> Pateikė</strong></td></tr>";
$a = 1;
while($data = dbarray($top)){
$result = dbquery("SELECT user_id FROM ".$db_prefix."users WHERE user_name='".$data['download_license']."'");
$data2 = dbarray($result);
if ($data['super'] == 1) {
$top2 = "<font color='red'><b>Super!</b></font>";
} else {
$top2 = "";
}
echo "<tr><td valign='top' class='cell'>$a.</td><td valign='top' class='cell'><a href='".seoname($data['download_title']."-ids".$data['download_id']).".html' title='Parsisiusti' class='side'>".$data['download_title']."</a>$top2</td><td class='cell'>".showdate("%Y.%m.%d", $data['download_datestamp'])."</td><td class='cell' align='center'>".$data['download_count']."</td><td class='cell' align='center'><a href='".seoname($data['download_license'])."-uid".$data2['user_id'].".html'>".$data['download_license']."</a></td></tr>";
$a++;
}
echo "</table>";
closetable();
Parašė dalampacki· 2011 Sau. 5 16:01:53
#7
ooO dėkui veikia mldc ačiū, +11 tau.