Listar Usuários Cadastrados.
Autor: Smoke | Publicado: 2011-06-24T07:20:00-07:00

&nbsp; &lt;?
&nbsp; &nbsp; //Created By.Smoke acassio_gatuxo@hotmail.com\\
&nbsp; &nbsp; $host = 'SEUSQL\SQLEXPRESS';
&nbsp; &nbsp; $user = 'sa';
&nbsp; &nbsp; $pass = 'SUASENHA';
&nbsp; &nbsp; $connection_string = 'DRIVER={SQL Server};SERVER='.$host.';DATABASE=accountdb';
&nbsp; &nbsp; $connection = @odbc_connect($connection_string,$user,$pass) or die ("Não foi possivel se conectar!");
&nbsp; &nbsp; ?&gt;
&nbsp; &nbsp; &lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
&nbsp; &nbsp; &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&nbsp; &nbsp; &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt;
&nbsp; &nbsp; &lt;title&gt;Lista de Usuarios - Smoke&lt;/title&gt;
&nbsp; &nbsp; &lt;head&gt;
&nbsp; &nbsp; &lt;style type="text/css"&gt;
&nbsp; &nbsp; &lt;!--
&nbsp; &nbsp; body {
&nbsp; &nbsp; &nbsp; &nbsp;background-color: #333333;
&nbsp; &nbsp; &nbsp; &nbsp;color: #FFFAFA;
&nbsp; &nbsp; }
&nbsp; &nbsp; .title {
&nbsp; &nbsp; &nbsp; &nbsp;background-color: #999999;
&nbsp; &nbsp; &nbsp; &nbsp;-moz-border-radius-topright: 2em;
&nbsp; &nbsp; &nbsp; &nbsp;-moz-border-radius-topleft: 2em;
&nbsp; &nbsp; &nbsp; &nbsp;text-shadow: 0 0 0.3em #000000, 0 0 0.3em #000000;
&nbsp; &nbsp; }
&nbsp; &nbsp; .princ {
&nbsp; &nbsp; &nbsp; &nbsp;background-color: #CDC9C9;
&nbsp; &nbsp; &nbsp; &nbsp;-moz-border-radius: 2em 0;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; text-shadow: 0 0 0.3em #009ACD, 0 0 0.3em #009ACD;
&nbsp; &nbsp; }
&nbsp; &nbsp; .pr {
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; text-shadow: 0 0 0.3em #FFD700, 0 0 0.3em #FFD700;
&nbsp; &nbsp; }
&nbsp; &nbsp; --&gt;
&nbsp; &nbsp; &lt;/style&gt;&lt;/head&gt;
&nbsp; &nbsp; &nbsp;&lt;table width="499" border="0" align="center" cellpadding="0" cellspacing="0" class="boxTable2"&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;body&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;tr&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;td height="91" align="center" class="boxContent2"&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;div class="title"&gt;Lista de Todos os Usuarios Cadastrados no Servidor - By.Smoke&lt;/div&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;br&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;table align="center" cellpadding="1" cellspacing="1"&gt;
&nbsp; &nbsp; &lt;?
&nbsp; &nbsp; $query = "SELECT * FROM [accountdb].[dbo].[AllPersonalMember]";
&nbsp; &nbsp; $q = odbc_do($connection,$query);
&nbsp; &nbsp; &nbsp; &nbsp;while(odbc_fetch_row($q)){
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $id = odbc_result($q,2);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $pass = odbc_result($q,3);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $passp = odbc_result($q,5);
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ?&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;tr&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td height="26" class="princ" align="center"&gt;Conta&lt;/td&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td height="26" class="princ" align="center"&gt;Senha&lt;/td&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td height="26" class="princ" align="center"&gt;Senha Painel&lt;/td&gt;
&nbsp; &nbsp; &nbsp; &lt;/tr&gt;
&nbsp; &nbsp; &nbsp; &lt;tr&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td width="106" class="pr" height="32" align="center"&gt;&lt;?=$id?&gt;&lt;/td&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td width="142" class="pr" align="center"&gt;&lt;?=$pass?&gt;&lt;/td&gt;
&nbsp; &nbsp; &nbsp; &nbsp; &lt;td width="142" class="pr" align="center"&gt;&lt;?=$passp?&gt;&lt;/td&gt;
&nbsp; &nbsp; &nbsp;&lt;? } ?&gt;
&nbsp; &nbsp; &nbsp;&lt;/table&gt;
&nbsp; &nbsp; &lt;/td&gt;