<span style=
"color: #000000;"
>php
</span><span style=
"color: #800080;"
>
$mysql_server_name
</span>=
"localhost"
; <span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$mysql_username
</span>=
"root"
; <span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$mysql_password
</span>=
"root"
; <span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$mysql_database
</span>=
"lxr"
; <span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$conn
</span>=<span style=
"color: #008080;"
>mysql_connect</span>(<span style=
"color: #800080;"
>
$mysql_server_name
</span>, <span style=
"color: #800080;"
>
$mysql_username
</span>,
<span style=
"color: #800080;"
>
$mysql_password
</span><span style=
"color: #000000;"
>);
</span><span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$strsql
</span>=
"select * from personal_info"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$result
</span>=<span style=
"color: #008080;"
>mysql_db_query</span>(<span style=
"color: #800080;"
>
$mysql_database
</span>, <span style=
"color: #800080;"
>
$strsql
</span>, <span style=
"color: #800080;"
>
$conn
</span><span style=
"color: #000000;"
>);
</span><span style=
"color: #008000;"
>
<span style=
"color: #800080;"
>
$row
</span>=<span style=
"color: #008080;"
>mysql_fetch_row</span>(<span style=
"color: #800080;"
>
$result
</span><span style=
"color: #000000;"
>);
</span><span style=
"color: #0000ff;"
>
echo
</span>
'<font face="verdana">'
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
echo
</span>
'<table border="1" cellpadding="1" cellspacing="2">'
<span style=
"color: #000000;"
>;
</span><span style=
"color: #008000;"
>
<span style=
"color: #0000ff;"
>
echo
</span>
"/n<tr>/n"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
for
</span> (<span style=
"color: #800080;"
>
$i
</span>=0; <span style=
"color: #800080;"
>
$i
</span>mysql_num_fields(<span style=
"color: #800080;"
>
$result
</span>); <span style=
"color: #800080;"
>
$i
</span>++<span style=
"color: #000000;"
>)
{
</span><span style=
"color: #0000ff;"
>
echo
</span>
'<td bgcolor="#000F00"><b>'
.
<span style=
"color: #008080;"
>mysql_field_name</span>(<span style=
"color: #800080;"
>
$result
</span>, <span style=
"color: #800080;"
>
$i
</span><span style=
"color: #000000;"
>);
</span><span style=
"color: #0000ff;"
>
echo
</span>
"</b></td>/n"
<span style=
"color: #000000;"
>;
}
</span><span style=
"color: #0000ff;"
>
echo
</span>
"</tr>/n"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #008000;"
>
<span style=
"color: #008080;"
>mysql_data_seek</span>(<span style=
"color: #800080;"
>
$result
</span>, 0<span style=
"color: #000000;"
>);
</span><span style=
"color: #008000;"
>
<span style=
"color: #0000ff;"
>
while
</span> (<span style=
"color: #800080;"
>
$row
</span>=<span style=
"color: #008080;"
>mysql_fetch_row</span>(<span style=
"color: #800080;"
>
$result
</span><span style=
"color: #000000;"
>))
{
</span><span style=
"color: #0000ff;"
>
echo
</span>
"<tr>/n"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
for
</span> (<span style=
"color: #800080;"
>
$i
</span>=0; <span style=
"color: #800080;"
>
$i
</span>mysql_num_fields(<span style=
"color: #800080;"
>
$result
</span>); <span style=
"color: #800080;"
>
$i
</span>++<span style=
"color: #000000;"
> )
{
</span><span style=
"color: #0000ff;"
>
echo
</span>
'<td bgcolor="#00FF00">'
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
echo
</span>
"<span style="
color: #800080;
">$row</span>[<span style="
color: #800080;
">$i</span>]"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
echo
</span>
'</td>'
<span style=
"color: #000000;"
>;
}
</span><span style=
"color: #0000ff;"
>
echo
</span>
"</tr>/n"
<span style=
"color: #000000;"
>;
}
</span><span style=
"color: #0000ff;"
>
echo
</span>
"</table>/n"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #0000ff;"
>
echo
</span>
"</font>"
<span style=
"color: #000000;"
>;
</span><span style=
"color: #008000;"
>
<span style=
"color: #008080;"
>mysql_free_result</span>(<span style=
"color: #800080;"
>
$result
</span><span style=
"color: #000000;"
>);
</span><span style=
"color: #008000;"
>
<span style=
"color: #008080;"
>mysql_close</span><span style=
"color: #000000;"
>();
</span>?>