Advertisement
faidhi

SYMBOL PHP/HTML

Mar 18th, 2017
92
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 1.54 KB | None | 0 0
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html>
  3. <?php  ?>
  4. <head>
  5.     <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  6. </head>
  7. <body>
  8. <?php
  9.     header('Content-type: text/html; charset=ISO-8859-1');
  10.     header('Content-type: text/html; charset=ISO-8859-2');
  11.     header('Content-type: text/html; charset=ISO-8859-3');
  12.     header('Content-type: text/html; charset=ISO-8859-4');
  13.     header('Content-type: text/html; charset=ISO-8859-5');
  14.     header('Content-type: text/html; charset=ISO-8859-6');
  15.     header('Content-type: text/html; charset=ISO-8859-7');
  16.     header('Content-type: text/html; charset=ISO-8859-8');
  17.     header('Content-type: text/html; charset=ISO-8859-9');
  18.     header('Content-type: text/html; charset=ISO-8859-10');
  19.     header('Content-type: text/html; charset=ISO-8859-15');
  20.    
  21.     $dbhost = 'DRIVER={SQL Server};SERVER=H251267VM\SQLEXPRESS;DATABASE=DB_Tank';
  22.     $dbuser = "sa";
  23.     $dbpass = "DDTankMalay123";
  24.    
  25.     $connection = odbc_connect($dbhost, $dbuser, $dbpass);
  26.  
  27.     $query = "SELECT TOP 10 NickName,FightPower FROM Sys_Users_Detail WHERE IsExist = 'True' ORDER by FightPower DESC";
  28.        
  29.     echo '<table align="center" ><tr>';
  30.    
  31.     $rank = odbc_exec($connection, $query);
  32.  
  33.     $i = 1;
  34.     while($db = odbc_fetch_array($rank))
  35.     {
  36.         echo '<td width="50" align="left">'.$i.'</td>';
  37.         echo '<td width="300" align="left">'.$db['NickName'].'</td>';
  38.         echo '<td width="150" align="left">'.$db['FightPower'].'</td>';
  39.         echo '</tr>';
  40.         $i++;
  41.     }
  42. echo '</table>';
  43. ?>
  44. </body>
  45. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement