Jump to content

Recommended Posts

Posted

Hi guys. I really need your help.

I have lineage 2 tops server www.top.la2tops.nbd.lt and i need add server "top5" in my ipb forum

 

llb.lt have this plugin.

 

HERE IS MY CODE:

 

<?php
   $server_ip = "localhost";
   $mysql_user = "tralalal";
   $mysql_pass = "lalalala";
   $database = "lalalal";
   
   $connect = mysql_connect("$server_ip", "$mysql_user", "$mysql_pass");
   if(!$connect){
      die('Negaliu prisijungti:'. mysql_error());
   }
   $db_select = mysql_select_db("$database", $connect);
   if(!$db_select){
      die('Nerasta Duomenu baze:'. mysql_error());
   }
   
   $top = mysql_query("SELECT id, title, votes FROM servers ORDER BY votes DESC LIMIT 10");
   $pos = 0;
   echo"<table  cellspacing='5'  border='0'>";
   echo"<tr><td>Nr.</td><td>Taskai</td><td>Serveris</td></tr>";
   while($row=mysql_fetch_array($top)){
      $pvpkill = $row['title'];
      $nick = $row['votes'];
      $pos++;
      echo"<tr><td>$pos.</td><td>$nick</td><td>$pvpkill</td></tr>";
   }   
   echo"</table>";
   mysql_close($connect);
?>

 

I modified it from top pvp .php script:D

Only one problem. How to to that when some press on server name he goes to server website? :)

 

Thanks.

 

P.s I DONT WANT TO ADVERTISE SOMETHING HERE. JUST NEED HELP :)

Posted

change the echo"<tr><td>Nr.</td><td>Taskai</td><td>Serveris</td></tr>";

to

echo "<tr><td>Nr.</td><td><a href="server website">Taskai</a></td><td>Serveris</td></tr>";

Posted

Ok, I see you didin't get it. Nevermind.

Let's do it other way.

 

<?php
if(!defined('SYS_STARTED')) die('Security activated');

$three_first_images = array(
1 => "<img src='{$theme_path}/images/icons/gold_medal_small.png' style='margin-left: -5px;' alt=''>", 
"<img src='{$theme_path}/images/icons/silver_medal_small.png' style='margin-left: -5px;' alt=''>", 
"<img src='{$theme_path}/images/icons/bronze_medal_small.png' style='margin-left: -5px;' alt=''>"
);
$servers_list = array();

$query = $db->prepare("SELECT *,rank FROM (
SELECT @rank := IF(@prev_val=votes,@rank,@rank+1) AS rank, @prev_val := votes AS 
votes, id, user_id, title, web_url, chronicle, xp, description, game_server_status, login_server_status
FROM servers WHERE deleted = '0' ORDER BY votes DESC, last_vote_date DESC
)as result LIMIT 5");
$query->execute();

if ($query->rowCount() > 0) {
$i = 1;
foreach ($query->fetchAll() as $key => $value) {
	$rank = get_server_rank($value['user_id']);

	$value['rank'] = (isset($three_first_images[$rank])) ? "<div class='server_rank_add'><strong>{$rank}</strong></div>" : "<div class='server_rank_add'>{$rank}</div>";
	$value['short_title'] = truncate(strtolower($value['title']), 25);
	$value['_id'] = $i;

	$servers_list[] = $value;
	++$i;
}
}

$tpl->assign('servers_list', $servers_list);	
$tpl->draw('top5');
?>

 

This is code of Top_5.php.

But when i go that file it says me "Security activated"... what should i do that top5 work?

  • 2 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Posts

    • SocNet x Dolphin Anty Partnership — Reaching New Heights Together! We’re excited to announce our new partnership with the anti-detect browser Dolphin Anty! Thank you for your trust and support — it's because of you that we continue to grow, expand, and bring even more value and opportunities to our customers. This partnership with Dolphin Anty offers more convenience, security, and flexibility for your work and automation needs. Read more on Dolphin Anty’s official blog: https://dolphin-anty.com/blog/en/socnet-and-dolphin-anty/ We’re also looking for new suppliers! — Snapchat accounts — Reddit accounts with karma — LinkedIn accounts with connections Contact us via DM or support to discuss terms — we’re always open to partnership proposals! Explore our online store: ➡ Accounts: Telegram, Facebook, Reddit, Twitter (X), Instagram, YouTube, TikTok, Discord, VK, LinkedIn, GitHub, Snapchat, Gmail, and emails (Outlook, Firstmail, Rambler, Onet, Gazeta, GMX, Yahoo, Proton, Web.de), Google Voice, Google Ads ➡ Premium Subscriptions: Telegram Premium, Twitter X Premium, YouTube Premium, Spotify Premium, Netflix Premium, Discord Nitro, ChatGPT Plus/PRO, XBOX Game Pass ➡ Additional Services: Telegram Stars, proxies (IPv4, IPv6, ISP, Mobile), VPNs (Outline, WireGuard, others), VDS/RDP servers To celebrate the partnership, use promo code DOLPHIN15 for 15% off in our online store! SMM Panel Services: ➡ Use our SMM Panel to boost: Facebook, Instagram, Telegram, Spotify, SoundCloud, YouTube, Reddit, Threads, Kick, Discord, LinkedIn, Likee, VK, Twitch, Kwai, website traffic, TikTok, TrustPilot, Apple Music, TripAdvisor, Snapchat, and more. Get $1 Trial Credit for your first SMM Panel launch: Just submit a support ticket titled "Get Trial Bonus" on our website. ➡ Go to the SMM Panel (clickable) or contact support via bot. Our Key Products: ➡ Online Store: Click ➡ Telegram Store Bot: Click ➡ SMM Panel: Click Payment methods: bank cards · crypto · other popular methods Returning customers get extra discounts & promo codes! Support Contacts: ➡ Telegram: https://t.me/solomon_bog ➡ Discord: https://discord.gg/y9AStFFsrh ➡ WhatsApp: https://wa.me/79051904467 ➡ ✉ Email: solomonbog@socnet.store ➡ Telegram Channel: https://t.me/accsforyou_shop You can also use these contacts to: — consult about bulk purchases — propose partnerships (our partners: https://socnet.bgng.io/partners ) — become a supplier SocNet — Digital Goods & Premium Subscriptions Store
    • SocNet x Dolphin Anty Partnership — Reaching New Heights Together! We’re excited to announce our new partnership with the anti-detect browser Dolphin Anty! Thank you for your trust and support — it's because of you that we continue to grow, expand, and bring even more value and opportunities to our customers. This partnership with Dolphin Anty offers more convenience, security, and flexibility for your work and automation needs. Read more on Dolphin Anty’s official blog: https://dolphin-anty.com/blog/en/socnet-and-dolphin-anty/ We’re also looking for new suppliers! — Snapchat accounts — Reddit accounts with karma — LinkedIn accounts with connections Contact us via DM or support to discuss terms — we’re always open to partnership proposals! Explore our online store: ➡ Accounts: Telegram, Facebook, Reddit, Twitter (X), Instagram, YouTube, TikTok, Discord, VK, LinkedIn, GitHub, Snapchat, Gmail, and emails (Outlook, Firstmail, Rambler, Onet, Gazeta, GMX, Yahoo, Proton, Web.de), Google Voice, Google Ads ➡ Premium Subscriptions: Telegram Premium, Twitter X Premium, YouTube Premium, Spotify Premium, Netflix Premium, Discord Nitro, ChatGPT Plus/PRO, XBOX Game Pass ➡ Additional Services: Telegram Stars, proxies (IPv4, IPv6, ISP, Mobile), VPNs (Outline, WireGuard, others), VDS/RDP servers To celebrate the partnership, use promo code DOLPHIN15 for 15% off in our online store! SMM Panel Services: ➡ Use our SMM Panel to boost: Facebook, Instagram, Telegram, Spotify, SoundCloud, YouTube, Reddit, Threads, Kick, Discord, LinkedIn, Likee, VK, Twitch, Kwai, website traffic, TikTok, TrustPilot, Apple Music, TripAdvisor, Snapchat, and more. Get $1 Trial Credit for your first SMM Panel launch: Just submit a support ticket titled "Get Trial Bonus" on our website. ➡ Go to the SMM Panel (clickable) or contact support via bot. Our Key Products: ➡ Online Store: Click ➡ Telegram Store Bot: Click ➡ SMM Panel: Click Payment methods: bank cards · crypto · other popular methods Returning customers get extra discounts & promo codes! Support Contacts: ➡ Telegram: https://t.me/solomon_bog ➡ Discord: https://discord.gg/y9AStFFsrh ➡ WhatsApp: https://wa.me/79051904467 ➡ ✉ Email: solomonbog@socnet.store ➡ Telegram Channel: https://t.me/accsforyou_shop You can also use these contacts to: — consult about bulk purchases — propose partnerships (our partners: https://socnet.bgng.io/partners ) — become a supplier SocNet — Digital Goods & Premium Subscriptions Store
    • Wipe. Open Date: 2025-08-02, 18:00 GMT+2
    • the price is 220 + Payment Systems?
  • Topics

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disabled AdBlock