Gentics Portal.Node PHP API
 All Classes Namespaces Functions Variables Pages
PreviewController.php
1 <?php
2 /**
3  * Gentics Portal.Node PHP
4  * Author & Copyright (c) by Gentics Software GmbH
5  * sales@gentics.com
6  * http://www.gentics.com
7  * Licenses can be found in the LICENSE.txt file in the root-folder of this installation
8  * You must not use this software without a valid license agreement.
9  *
10  *
11  * @author Vitalii Kovalchuk <vitaly.kovalchuk@oberig.com>
12  */
13 
14 /**
15  * Comment controller class
16  *
17  * @author Vitalii Kovalchuk <vitaly.kovalchuk@oberig.com>
18  *
19  */
20 class PreviewController extends Controller
21 {
22 
23  /**
24  * default action used to like or unlike content
25  *
26  * @return bool
27  */
28  public function actionIndex()
29  {
30  if (isset($_GET['lang'])) {
31  Yii::app()->language = $_GET['lang'];
32  }
33 
34  $contentId = Yii::app()->request->getQuery('contentId', 0);
35 
36  $this->renderPartial('LikeWidget', array('contentId' => $contentId));
37  }
38 }