Location: PHPKode > projects > PLiMa > plima-0.5.2/inc/form-search.inc.php
<?
/***
	*   pLiMa - php List Manager
  *   Copyright (C) 2003  Jinn Koriech (hide@address.com)
	*
  *		This file is part of pLiMa.
	*
	*   pLiMa is free software; you can redistribute it and/or modify
	*   it under the terms of the GNU General Public License as published by
	*   the Free Software Foundation; either version 2 of the License, or
	*   any later version.
	*
	*   pLiMa is distributed in the hope that it will be useful,
	*   but WITHOUT ANY WARRANTY; without even the implied warranty of
	*   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	*   GNU General Public License for more details.
	*
	*   You should have received a copy of the GNU General Public License
	*   along with pLiMa; if not, visit http://www.gnu.org or write to the 
	*   Free Software Foundation, Inc., 59 Temple Place, Suite 330, 
	*	  Boston, MA  02111-1307  USA
	*	
	*/
?><form name="search" method="post" action="search.phtml">
	<select name="field">
	<?
		$fields = mysql_list_fields(DB_NAME, $_SESSION['MALI']);
		$columns = mysql_num_fields($fields);
		
		for ($i = 0; $i < $columns; $i++) {
			$field = mysql_field_name($fields,$i);
			if ( $field != 'userid' ) {
	 	  	echo "<option>".mysql_field_name($fields, $i) . "</option>\n";
			}
		}
	?>
	</select>
  for
	<input type="text" name="query" />
	<input type="submit" name="search" value="go get it!" />
</form>
Return current item: PLiMa