This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* AuthFilter class file. | |
* @author Christoffer Niska <ChristofferNiska@gmail.com> | |
* @copyright Copyright © Christoffer Niska 2012- | |
* @license http://www.opensource.org/licenses/bsd-license.php New BSD License | |
* @package auth.components | |
*/ | |
/** |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Registers a specific Bootstrap plugin with the given selector and options. | |
* @param string $name the plugin name. | |
* @param string $selector the CSS selector. | |
* @param array $options plugin JavaScript options. | |
* @param int $position the position of the JavaScript code. | |
*/ | |
public function registerPlugin($name, $selector, $options = array(), $position = CClientScript::POS_END) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Generates a button group. | |
* @param array $buttons the button configurations. | |
* @param array $htmlOptions additional HTML options. The following special options are recognized: | |
* todo: write the options | |
* @return string the generated button group. | |
*/ | |
public static function buttonGroup($buttons, $htmlOptions = array()) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* TbThumbnails class file. | |
* @author Christoffer Niska <christoffer.niska@gmail.com> | |
* @copyright Copyright © Christoffer Niska 2013- | |
* @license http://www.opensource.org/licenses/bsd-license.php New BSD License | |
* @package bootstrap.widgets | |
*/ | |
Yii::import('bootstrap.widgets.TbListView'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Class ModelGroupForm | |
* | |
* Note! Attributes must be defined as "modelName.attributeName", e.g. "user.name" in forms. | |
*/ | |
class ModelGroupForm extends CFormModel { | |
/** | |
* @var CModel[] $models the model instances (name=>config). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
defined('DS') or define('DS', DIRECTORY_SEPARATOR); | |
/** | |
* Returns the application instance. | |
* @return CWebApplication | |
*/ | |
function app() { | |
return Yii::app(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Attribute id: | |
frontend\models\UserRegisterForm_profile:availabilityDate | |
// jQuery selector before escaping: | |
#frontend\models\UserRegisterForm_profile:availabilityDate | |
// jQuery selector after escaping using the snippet below: | |
frontend\\\\models\\\\UserRegisterForm_profile\\:availabilityDate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* ConfigBuilder class file. | |
* @author Christoffer Niska <christoffer.niska@gmail.com> | |
* @copyright Copyright © Christoffer Niska 2013- | |
* @license http://www.opensource.org/licenses/bsd-license.php New BSD License | |
*/ | |
/** | |
* Helper for building application configurations. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function buildMenuRecursive($parentID = 0) { | |
$result = array(); | |
$menus = Menus::model()->getMenusUsuarios($parentID); | |
foreach ($menus as $key => $value) { | |
$result[$key] = array( | |
'name' => $value['title'], | |
'link' => $value['url'] ? Yii::app()->createUrl($value['url']) : '', | |
'visible' => $value['status'], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* FacebookConnect class file. | |
* @author Christoffer Niska <ChristofferNiska@gmail.com> | |
* @copyright Copyright © Christoffer Niska 2011- | |
* @license http://www.opensource.org/licenses/bsd-license.php New BSD License | |
*/ | |
/** | |
* Facebook connection application component. |