Devam Ediyor

private project for sasi

we need redesign this script

so the output is in proper formart

$db_handle = mysql_connect($hostname, $user, $pass) or die (mysql_error());

$db_selected = mysql_select_db($dbname, $db_handle) or die (mysql_error());

$i=0;

$valid =0;

$begin = 0;

$cat = array();

if($db_selected)

{

$query_left = mysql_query("SHOW COLUMNS FROM ZipData") or die (mysql_error());

$query_right_string = "SELECT * FROM `ZipData` WHERE ZipCode='".$zipcode."' LIMIT 1" ;

//echo $query_right_string;

$query_right = mysql_query($query_right_string) or die (mysql_error());

while($result_left = mysql_fetch_array($query_left)){

$cat[$i] = $result_left[0];

$i++;

}

while($result_right = mysql_fetch_array($query_right))

{

//echo $result_right['Population'];

if(intval($result_right['Population']) >0 )

{

$valid = 1;

if($begin == 0 && intval($result_right['Population']) > 1)

{

$print = $print = '<table><h3>Census data from the the latest cansus in 2010 for zip code '.$zipcode.':</h3>';

$begin =0;

}

for($j = 1;$j<$i;$j++)

{

$print .= "<tr><td>".$cat[$j]."</td><td>".$result_right[$cat[$j]]."</td></tr>";

}

}

}

}

$print .= '</table>';

if($valid == 1)

{

echo $print;

}

?>

Beceriler: PHP

Daha fazlasını görün: sasi, census, private show, census data, script zipcode, project private, php select show page, javascript select show selected, oracle select show decimals, project private villa, population project, project private chat room, wow project private server, private project script, need redesign project

İşveren Hakkında:
( 38 değerlendirme ) new britain, United States

Proje NO: #6502787

Seçilen:

sasi0515

Hired by the Employer

4 gün içinde 20$ USD
(24 Değerlendirme)
4.2