diff options
author | ctrlaltca@gmail.com <> | 2011-06-02 11:16:04 +0000 |
---|---|---|
committer | ctrlaltca@gmail.com <> | 2011-06-02 11:16:04 +0000 |
commit | ffc9318788952a879815cfa01a8b17b7ddae89b1 (patch) | |
tree | 2617fc3a77ca6372f0c6cb3d0775c4007b6208b9 /demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php | |
parent | 8aa0d56705a71894a80c1293730b6c67cddc8a40 (diff) |
added documentation and examples for TActiveCheckBoxList, TActiveDropDownList, TActiveListBox, TActiveRadioButtonList classes
Diffstat (limited to 'demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php')
-rw-r--r-- | demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php b/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php new file mode 100644 index 00000000..dfa52ce4 --- /dev/null +++ b/demos/quickstart/protected/pages/ActiveControls/Samples/TActiveRadioButtonList/Home.php @@ -0,0 +1,26 @@ +<?php
+
+class Home extends TPage
+{
+ protected function collectSelectionResult($input,$output)
+ {
+ $indices=$input->SelectedIndices;
+ $result='';
+ foreach($indices as $index)
+ {
+ $item=$input->Items[$index];
+ $result.="(Index: $index, Value: $item->Value, Text: $item->Text)";
+ }
+ if($result==='')
+ $output->Text='Your selection is empty.';
+ else
+ $output->Text='Your selection is: '.$result;
+ }
+
+ public function selectionChanged($sender,$param)
+ {
+ $this->collectSelectionResult($this->RadioButtonList,$this->SelectionResult);
+ }
+}
+
+?>
\ No newline at end of file |