summaryrefslogtreecommitdiff
path: root/demos/blog/protected/Pages/Posts/NewCategory.php
diff options
context:
space:
mode:
Diffstat (limited to 'demos/blog/protected/Pages/Posts/NewCategory.php')
-rw-r--r--demos/blog/protected/Pages/Posts/NewCategory.php80
1 files changed, 40 insertions, 40 deletions
diff --git a/demos/blog/protected/Pages/Posts/NewCategory.php b/demos/blog/protected/Pages/Posts/NewCategory.php
index 5df0c85b..b5bf26e9 100644
--- a/demos/blog/protected/Pages/Posts/NewCategory.php
+++ b/demos/blog/protected/Pages/Posts/NewCategory.php
@@ -1,41 +1,41 @@
-<?php
-/**
- * NewCategory class file
- *
- * @author Qiang Xue <qiang.xue@gmail.com>
- * @link http://www.pradosoft.com/
- * @copyright Copyright &copy; 2006 PradoSoft
- * @license http://www.pradosoft.com/license/
- * @version $Id$
- */
-
-/**
- * NewCategory class
- *
- * @author Qiang Xue <qiang.xue@gmail.com>
- * @link http://www.pradosoft.com/
- * @copyright Copyright &copy; 2006 PradoSoft
- * @license http://www.pradosoft.com/license/
- */
-class NewCategory extends BlogPage
-{
- public function saveButtonClicked($sender,$param)
- {
- if($this->IsValid)
- {
- $categoryRecord=new CategoryRecord;
- $categoryRecord->Name=$this->CategoryName->Text;
- $categoryRecord->Description=$this->CategoryDescription->Text;
- $this->DataAccess->insertCategory($categoryRecord);
- $this->gotoPage('Posts.ListPost',array('cat'=>$categoryRecord->ID));
- }
- }
-
- public function checkCategoryName($sender,$param)
- {
- $name=$this->CategoryName->Text;
- $param->IsValid=$this->DataAccess->queryCategoryByName($name)===null;
- }
-}
-
+<?php
+/**
+ * NewCategory class file
+ *
+ * @author Qiang Xue <qiang.xue@gmail.com>
+ * @link http://www.pradosoft.com/
+ * @copyright Copyright &copy; 2006 PradoSoft
+ * @license http://www.pradosoft.com/license/
+ * @version $Id$
+ */
+
+/**
+ * NewCategory class
+ *
+ * @author Qiang Xue <qiang.xue@gmail.com>
+ * @link http://www.pradosoft.com/
+ * @copyright Copyright &copy; 2006 PradoSoft
+ * @license http://www.pradosoft.com/license/
+ */
+class NewCategory extends BlogPage
+{
+ public function saveButtonClicked($sender,$param)
+ {
+ if($this->IsValid)
+ {
+ $categoryRecord=new CategoryRecord;
+ $categoryRecord->Name=$this->CategoryName->Text;
+ $categoryRecord->Description=$this->CategoryDescription->Text;
+ $this->DataAccess->insertCategory($categoryRecord);
+ $this->gotoPage('Posts.ListPost',array('cat'=>$categoryRecord->ID));
+ }
+ }
+
+ public function checkCategoryName($sender,$param)
+ {
+ $name=$this->CategoryName->Text;
+ $param->IsValid=$this->DataAccess->queryCategoryByName($name)===null;
+ }
+}
+
?> \ No newline at end of file