I have created a core 42 field and added some code in
prepare form text area:
$con=mysqli_connect("localhost","root","password","dbname");
echo $form = "<select id='gvid' name='gvid' ><option value=''> --Select-- </option>";
$sql = mysqli_query($con,"SELECT * FROM `qmebd_cck_store_form_m_block` LIMIT 0, 30");
while($result = mysqli_fetch_array($sql))
{
echo "<OPTION VALUE='".$result[0]."'>".$result[0]."</OPTION>";
}
echo "</select>";
It is working! and showing a select field in form, But not in the right place assigned to the field. the select field is showing
at the top of the form.at the right position I am getting
one more select field which is showing only ---select--- option.Can anyone shed some light?