can you help me,, how can i put the flags of the user in the online list, thankz
Flags in ONline list
Collapse
X
-
Originally posted by hunter-x-hunter View Postcan you help me,, how can i put the flags of the user in the online list, thankzIt's better to keep your mouth shut and give the impression that you're stupid, than to open it and remove all doubt.
ⓣⓗⓔ ⓠⓤⓘⓔⓣⓔⓡ ⓨⓞⓤ ⓑⓔ©ⓞⓜⓔ, ⓣⓗⓔ ⓜⓞⓡⓔ ⓨⓞⓤ â“â“¡â“” â“ⓑⓛⓔ ⓣⓞ â“—â“”â“â“¡ !
ιη тнєσÑу, тнє ÏÑα¢тι¢є ιѕ α Ñєѕυℓт σƒ тнє тнєσÑу, вυт ιη ÏÑα¢тι¢є ιѕ тнє σÏÏσѕιтє.
-
here are my online script get the code u want from here
Code://////////////////////////////////////////// else if($action=="online") { addonline(getuid_sid($sid),"Online List - xHTML","index.php?action=$action"); //////ALL LISTS SCRIPT << if($page=="" || $page<=0)$page=1; $num_items = getnumonline(); //changable $items_per_page= 10; $num_pages = ceil($num_items/$items_per_page); if($page>$num_pages)$page= $num_pages; $limit_start = ($page-1)*$items_per_page; //changable sql $sql = "SELECT a.name, b.place, b.userid, a.onlinemsg, sex, perms FROM ibwf_users a INNER JOIN online b ON a.id = b.userid GROUP BY 1,2 LIMIT $limit_start, $items_per_page "; echo "<p><small>"; echo "<div class=\"box_cen\" align=\"center\">"; echo "<b>Users Online</b>"; echo "<div class=\"box_sub\" align=\"left\">"; $mols = mysql_fetch_array(mysql_query("SELECT name, value FROM ibwf_settings WHERE id='2'")); print "Most online: <b>$mols[1]</b><br/>"; $mols = mysql_fetch_array(mysql_query("SELECT ppl, dtm FROM ibwf_mpot WHERE ddt='".date("d m y")."'")); print "Most online today only: <b>$mols[0]</b><br/>"; $kazz = mysql_fetch_array(mysql_query("SELECT count(a.userid) FROM online a,ibwf_members b where a.userid=b.id and b.sex='F' ")); echo "Female <a href=\"index.php?action=fonline&sid=$sid\"> [$kazz[0]]</a>»"; $kazz = mysql_fetch_array(mysql_query("SELECT count(a.userid) FROM online a,ibwf_users b where a.userid=b.id and b.sex='M' ")); echo "Male <a href=\"index.php?action=monline&sid=$sid\"> [$kazz[0]]</a><br/>"; $timeout = 180; $timeon = time()-$timeout; $noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_users WHERE perm>'0' AND lastact>'".$timeon."' ")); echo "Staff Online: <a href=\"index.php?action=stfol&sid=$sid\">".$noi[0]."</a><br/>"; echo"</center><hr/>"; $items = mysql_query($sql); echo mysql_error(); while ($item = mysql_fetch_array($items)) { $uipadd = mysql_fetch_array(mysql_query("SELECT ipadd FROM ibwf_users WHERE id='".$item[2]."'")); $IPaddress=$uipadd[0]; $two_letter_country_code=iptocountry($IPaddress); echo "</br><img src=\"flags/$two_letter_country_code.png\" alt=\"*\"/>"; $avlink = getavatar($item[2]); if ($avlink!=""){ echo "<img src=\"$avlink\" height=\"25\" width=\"25\" alt=\"avatar\"/>"; }else{ echo "<img src=\"images/nopic.jpg\" height=\"25\" width=\"25\" alt=\"avatar\"/>"; } $sex = mysql_fetch_array(mysql_query("SELECT sex FROM ibwf_users WHERE name='$item[0]'")); if($sex[0]=="M"){$usersex = "I'm Male <img src=\"images/male1.gif\" alt=\"M\"/><br/>";} if($sex[0]=="F"){$usersex = "I'm Female <img src=\"images/female1.gif\" alt=\"F\"/><br/>";} if($sex[0]==""){$usersex = "I'm a dreamerz freak..<img src=\"images/freak.gif\" alt=\"F\"/><br/>";} if ($item[4]=="1") { $lnk = "<a class=\"mod\" href=\"index.php?action=viewuser&who=$item[2]&sid=$sid\">$item[0]</a>"; } else if ($item[4]=="2") { $lnk = "<a class=\"admin\" href=\"index.php?action=viewuser&who=$item[2]&sid=$sid\">$item[0]</a>"; } else if ($item[4]=="3") { $lnk = "<a class=\"owner\" href=\"index.php?action=viewuser&who=$item[2]&sid=$sid\">$item[0]</a>"; } else if ($item[4]=="4") { $lnk = "<a class=\"head admin\" href=\"index.php?action=viewuser&who=$item[2]&sid=$sid\">$item[0]</a>"; } else { $lnk = "<a href=\"index.php?action=viewuser&who=$item[2]&sid=$sid\">$item[0]</a><br/>"; } $text = parsepm($item[3], $sid); $onmsg = "~ <font color=\"blue\">$text</font>~"; // echo "$icon $lnk - $item[1]"; $whereami = mysql_fetch_array(mysql_query("SELECT placedet FROM ibwf_online WHERE userid='$item[2]'")); if ($whereami[0]=="") { $myloc = $item[1]; } else { $myloc = "<a href=\"$whereami[0]&sid=$sid\">$item[1]</a>"; } echo "$lnk - $pm <b>·</b>$icon $usersex<font color=\"green\"><b>· Where : </b>$myloc</font> <br/>$tit"; echo "<b>·</b> Online Msg : $onmsg<br/>"; echo "<b>Country:</b> $two_letter_country_code<br/>"; echo "·········</br>"; } echo "</small></p>"; echo "<p align=\"center\">"; if($page>1) { $ppage = $page-1; echo "<a href=\"index.php?action=online&page=$ppage&sid=$sid\">«PREV</a> "; } if($page<$num_pages) { $npage = $page+1; echo "<a href=\"index.php?action=online&page=$npage&sid=$sid\">Next»</a>"; } echo "<br/>$page/$num_pages<br/>"; if($num_pages>2) { echo getjumper($action, $sid,"index"); } echo "</p>"; ////// UNTILL HERE >> echo "<p align=\"center\">"; echo "<div class=\"box_sub\" align=\"left\">"; echo "<b>Update Online Msg</b>"; echo "<form action=\"index.php?action=uponmsg&sid=$sid\" method=\"post\">"; echo "Text:<input name=\"text\" maxlength=\"100\" value=\"$dmsg\"/><br/>"; echo "<input type=\"submit\" value=\"Save\"/>"; echo "</form><br/></div>"; $thid = mysql_fetch_array(mysql_query("SELECT themeid FROM ibwf_users WHERE id='".$uid."'")); $themeimageset = mysql_fetch_array(mysql_query("SELECT themedir FROM ibwf_iconset WHERE id='".$thid[0]."'")); echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/themes/$themeimageset[0]/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo "</p></div>"; exit(); }
Code://////////////////////Country function iptocountry($ip) { $numbers = preg_split( "/\./", $ip); include("ip_files/".$numbers[0].".php"); $code=($numbers[0] * 16777216) + ($numbers[1] * 65536) + ($numbers[2] * 256) + ($numbers[3]); foreach($ranges as $key => $value){ if($key<=$code){ if($ranges[$key][0]>=$code){$two_letter_country_code=$ranges[$key][1];break;} } } if ($two_letter_country_code==""){$two_letter_country_code="unkown";} return $two_letter_country_code; } function country_name($two_letter_country_code) { include("ip_files/countries.php"); $country_name=$countries[$two_letter_country_code][0]; return $country_name; } function show_flag($two_letter_country_code) { $file_to_check='./flags/'.strtolower($two_letter_country_code).'.png'; if (file_exists($file_to_check)){ $FLAG= '<img src="'.$file_to_check.'" alt="'.$two_letter_country_code.'"/>'; }else{ $FLAG= '<img src="./flags/noflag.png" alt="'.$two_letter_country_code.'"/>'; } return $FLAG; }
Last edited by riderz; 15.08.10, 14:13.________________
Jacques
jacques@gw-designs.co.za
http://coding.biz.tm
Come join and lets make it a place to learn all the noobies how to code
__________________
NEVER FORGET TO CLICK THE TANX BUTTON IF U LIKE WHAT IM SHARING OR HELPING WITH
Comment
-
Originally posted by centi View Postif ya looking for this u cant code this using free ip2c... u need to buy one something else
i have 12.7mb
Originally posted by centi View Postif ya looking for this u cant code this using free ip2c... u need to buy one something else
i have 12.7mb
Comment
-
Originally posted by wapmetal View Postdone coding with my own.. you may look on Gothic IndusTrial Culture
done coding with my own.. you may look on Gothic IndusTrial Culture
may you plsss share, plsss i need it thankz,..
Comment
-
For free IP address geolocation database, IP address geolocation SQL database :: IPInfoDB . if you don't want to use a mysql database, you can use this free API service. IP location XML API :: IPInfoDB with php examples.
Or you can try for “Who Is Online” Widget With PHP, MySQL Tutorial: “Who Is Online” Widget With PHP, MySQL & jQuery | Tutorialzine
Free Mobile Web Scripts by me: Free Youtube Downloader, Tweets Reader, Facebook Wall Posts Reader
PHP Tutorials: How to Secure Your PHP Script (PHP SECURITY)
Want to Develop/Edit your WAP/Web Site? Add me to Gtalk (gmail) 'lakshan1989' or PM me.
Comment
Comment