64 |
* @param mixed - the value to look up |
* @param mixed - the value to look up |
65 |
* @return string - the text associated |
* @return string - the text associated |
66 |
*/ |
*/ |
67 |
function get_value_text($value) { |
function get_value_text() { |
68 |
|
$value = $this->get_value(); |
69 |
foreach( $this->_data_list as $arr) { |
foreach( $this->_data_list as $arr) { |
70 |
$flip = array_flip($arr); |
$flip = array_flip($arr); |
71 |
if ($flip[$value]) { |
if (isset($flip[$value])) { |
72 |
return $flip[$value]; |
return $flip[$value]; |
73 |
} |
} |
74 |
} |
} |
126 |
|
|
127 |
//now build the href so we can click on it. |
//now build the href so we can click on it. |
128 |
$attr["class"] ="form_link"; |
$attr["class"] ="form_link"; |
129 |
$attr["href"] = "#"; |
$attr["href"] = "javascript:void(0)"; |
130 |
$js = "javascript: function check(item){item.click();} ". |
$js = "javascript: function check(item){item.click();} ". |
131 |
"check(".$this->get_element_name().".item($index));"; |
"check(".$this->get_element_name().".item($index));"; |
132 |
$attr["onclick"] = $js; |
$attr["onclick"] = $js; |