diff options
| author | ctrlaltca <> | 2012-07-12 11:21:01 +0000 | 
|---|---|---|
| committer | ctrlaltca <> | 2012-07-12 11:21:01 +0000 | 
| commit | 903ae8a581fac1e6917fc3e31d2ad8fb91df80c3 (patch) | |
| tree | e08bf04f0823650a231227ac3499121270172a23 /demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete | |
| parent | 3e4e6e66aeb3f8fea4e1eb4237498ef9d2358f63 (diff) | |
standardize the use of unix eol; use svn properties to enforce native eol
Diffstat (limited to 'demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete')
| -rw-r--r-- | demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete/Home.php | 68 | 
1 files changed, 34 insertions, 34 deletions
diff --git a/demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete/Home.php b/demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete/Home.php index ca8a9e59..290995c7 100644 --- a/demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete/Home.php +++ b/demos/quickstart/protected/pages/ActiveControls/Samples/TAutoComplete/Home.php @@ -1,34 +1,34 @@ -<?php
 -// $Id$
 -class Home extends TPage
 -{
 -    public function suggestNames($sender,$param) {
 -        // Get the token
 -        $token=$param->getToken();
 -        // Sender is the Suggestions repeater
 -        $sender->DataSource=$this->getDummyData($token);
 -        $sender->dataBind();                                                                                                     
 -    }
 -
 -    public function suggestionSelected1($sender,$param) {
 -        $id=$sender->Suggestions->DataKeys[ $param->selectedIndex ];
 -        $this->Selection1->Text='Selected ID: '.$id;
 -    }
 -
 -    public function suggestionSelected2($sender,$param) {
 -        $id=$sender->Suggestions->DataKeys[ $param->selectedIndex ];
 -        $this->Selection2->Text='Selected ID: '.$id;
 -    }
 -
 -    public function getDummyData($token) {
 -        // You would look for matches to the given token here
 -        return array(
 -            array('id'=>1, 'name'=>'John'),
 -            array('id'=>2, 'name'=>'Paul'),
 -            array('id'=>3, 'name'=>'George'),
 -            array('id'=>4, 'name'=>'Ringo')
 -        );
 -    }
 -}
 -
 -?>
 +<?php +// $Id$ +class Home extends TPage +{ +    public function suggestNames($sender,$param) { +        // Get the token +        $token=$param->getToken(); +        // Sender is the Suggestions repeater +        $sender->DataSource=$this->getDummyData($token); +        $sender->dataBind();                                                                                                      +    } + +    public function suggestionSelected1($sender,$param) { +        $id=$sender->Suggestions->DataKeys[ $param->selectedIndex ]; +        $this->Selection1->Text='Selected ID: '.$id; +    } + +    public function suggestionSelected2($sender,$param) { +        $id=$sender->Suggestions->DataKeys[ $param->selectedIndex ]; +        $this->Selection2->Text='Selected ID: '.$id; +    } + +    public function getDummyData($token) { +        // You would look for matches to the given token here +        return array( +            array('id'=>1, 'name'=>'John'), +            array('id'=>2, 'name'=>'Paul'), +            array('id'=>3, 'name'=>'George'), +            array('id'=>4, 'name'=>'Ringo') +        ); +    } +} + +?>  | 
