@@ -89,8 +89,9 @@ class MessageController extends Controller {
if(isset($_POST['message'])){
$this->model->text=$_POST['message'];
$this->model->board=1;
$this->model->board=$_POST['board'];
$this->model->infotype=$_POST['infotype'];
if($this->model->validate()){
if($this->model->save()){
// Validate ok! Saving your data from form okay!
...
...
@@ -109,7 +110,7 @@ class MessageController extends Controller {
// Validate not ok!
// Send a response back!
header('Content-type: application/json');
echojson_encode(array('result'=>false,'data'=>'No Valid Data'));// Use CJSON::encode() instead of json_encode() if you are encoding a Yii model
echojson_encode(array('result'=>false,'data'=>'Validation Failed, No Valid Data','postdata'=>$_POST));// Use CJSON::encode() instead of json_encode() if you are encoding a Yii model
in /Users/kkrieger/htdocs/werkstatt/protected/controllers/MessageController.php (93)
in /Users/kkrieger/htdocs/werkstatt/index.php (13)
2014/04/19 11:05:46 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'The system is unable to find the requested action "view".' in /Users/kkrieger/htdocs/yii1114/framework/web/CController.php:483
2014/04/19 11:31:36 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'Unable to resolve the request "src/bootstrap-wysihtml5.js".' in /Users/kkrieger/htdocs/yii1114/framework/web/CWebApplication.php:286
2014/04/19 11:31:39 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'Unable to resolve the request "src/bootstrap-wysihtml5.js".' in /Users/kkrieger/htdocs/yii1114/framework/web/CWebApplication.php:286
2014/04/19 11:42:18 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'Unable to resolve the request "css/jquery.oembed.css".' in /Users/kkrieger/htdocs/yii1114/framework/web/CWebApplication.php:286
2014/04/19 11:42:21 [error] [exception.CHttpException.404] exception 'CHttpException' with message 'Unable to resolve the request "css/jquery.oembed.css".' in /Users/kkrieger/htdocs/yii1114/framework/web/CWebApplication.php:286