note 68206 deleted from function.oci-parse by sixd

From: Date: Wed, 11 Nov 2009 01:01:30 +0000
Subject: note 68206 deleted from function.oci-parse by sixd
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-162738@lists.php.net to get a copy of this message
Note Submitter: badr at arabiadata dot com ---- connecting to oracle database, get the data and insert it into a dynamic drop down box <?php $conn = oci_connect("$username", "$password", 'ora10g'); if (!$conn) { $e = oci_error(); print htmlentities($e['message']); exit; } ?> <SELECT name="name"> <?php $query2 = "SELECT EMP_NAME, EMP_CODE FROM HR_EMP where APP_USER='$suserid' "; $statement2 = oci_parse ($conn, $query2); oci_execute ($statement2); while ($row = oci_fetch_array ($statement2, OCI_NUM)) { ?> <option value="<? echo $row[1]; ?>"> <? echo $row[0] ?> </option> <? } ?> </select>

« previous php.notes (#162738) next »