Subversion-Projekte lars-tiefland.prado

Revision

Details | Letzte Änderung | Log anzeigen | RSS feed

Revision Autor Zeilennr. Zeile
1 lars 1
<?php
2
/**
3
 * SearchPortlet class file
4
 *
5
 * @author Qiang Xue <qiang.xue@gmail.com>
6
 * @link http://www.pradosoft.com/
7
 * @copyright Copyright &copy; 2006 PradoSoft
8
 * @license http://www.pradosoft.com/license/
9
 * @version $Id: SearchPortlet.php 1509 2006-11-25 20:51:43Z xue $
10
 */
11
 
12
Prado::using('Application.Portlets.Portlet');
13
 
14
/**
15
 * SearchPortlet class
16
 *
17
 * @author Qiang Xue <qiang.xue@gmail.com>
18
 * @link http://www.pradosoft.com/
19
 * @copyright Copyright &copy; 2006 PradoSoft
20
 * @license http://www.pradosoft.com/license/
21
 */
22
class SearchPortlet extends Portlet
23
{
24
	public function onInit($param)
25
	{
26
		parent::onInit($param);
27
		if(!$this->Page->IsPostBack && ($keyword=$this->Request['keyword'])!==null)
28
			$this->Keyword->Text=$keyword;
29
	}
30
 
31
	public function search($sender,$param)
32
	{
33
		$keyword=$this->Keyword->Text;
34
		$url=$this->Service->constructUrl('SearchPost',array('keyword'=>$keyword),false);
35
		$this->Response->redirect($url);
36
	}
37
}
38
 
39
?>