PHP Classes

File: multi_example.php

Recommend this page to a friend!
  Classes of sujith nair   multi   multi_example.php   Download  
File: multi_example.php
Role: ???
Content type: text/plain
Description: Example file to use "multi"
Class: multi
Author: By
Last change:
Date: 21 years ago
Size: 1,190 bytes


Class file image Download
<?php // Include the connection file include ""; // Include the class file include ""; //Modify ths according to your requirements. $sqltake="select COUNTRY from resume where RID='$rid'"; $restake=mysql_query($sqltake); $myrowtake=mysql_fetch_array($restake); // Define an Object $obj = new multi; ?> <!-- This is how it should be handled. Here the first argument is the Value stored in the database field. Second argument is the option value in the select form field.--> <select name="country" multiple> <option value="India" <?php echo $obj->sel($myrowtake["COUNTRY"],"India");?>>India</option> <option value="Afghanistan" <?php echo $obj->sel($myrowtake["COUNTRY"],"Afghanistan");?>>Afghanistan</option> <option value="Algeria" <?php echo $obj->sel($myrowtake["COUNTRY"],"Algeria");?>>Algeria</option> <option value="Australia" <?php echo $obj->sel($myrowtake["COUNTRY"],"Australia");?>>Australia</option> <option value="Austria" <?php echo $obj->sel($myrowtake["COUNTRY"],"Austria");?>>Austria</option> <option value="Bahrain" <?php echo $obj->sel($myrowtake["COUNTRY"],"Bahrain");?>>Bahrain</option> </select>