oh.. thanks...
i searched some ideas in optimizing php code in google and i try the tips that i\'ve found and it works fast..!! i make some optimization in the code that i given earlier base on the tips and i come up with this:
[php:1:6c213089bb]<?php
ob_start();
$id=mysql_connect(\"host\", \"username\", \"password\") or die(mysql_error());
mysql_select_db(\"databasename\", $id);
$rs = mysql_query(\"Select name from table_name\", $id) or die(mysql_error());
$opt = \"<select name=\'names\'>\";
do {
$opt.= \"<option value=\'\" . $row[\'name\'] . \"\'>\" . $row[\'name\'] . \"</option>\";
}
while($row=mysql_fetch_array($rs));
echo $opt . \"</option>\";
unset($opt);
ob_end_flush();
?>[/php:1:6c213089bb]