with('i18n')->find(array('order' => 'rand()'));
/** @var $photo GalleryPhoto */
$photo = GalleryPhoto::model()->with('i18n')->find(
array(
'condition' => 'gallery_id = :gal_id',
'order' => 'rand()',
'params' => array(
':gal_id' => $album->video_gallery_id
)
));
}
$url = $photo->i18n->link;
$matches = array();
preg_match('#(?<=(?:v|i)=)[a-zA-Z0-9-]+(?=&)|(?<=(?:v|i)\/)[^&\n]+|(?<=embed\/)[^"&\n]+|(?<=(?:v|i)=)[^&\n]+|(?<=youtu.be\/)[^&\n]+#', $url, $matches);
if (count($matches) > 0) {
$videoId = $matches[0];
$url = 'http://www.youtube.com/embed/' . $videoId . '?feature=player_detailpage';
}
?>
getUrl('small'), $photo->i18n->name), $url,array('rel'=>'video-feed','class'=>'iframe'))?>
i18n->name, $url,array('rel'=>'video-feed','class'=>'iframe'));?>
with('i18n')->find(array('order' => 'rand()'));
/** @var $photo GalleryPhoto */
$photo = GalleryPhoto::model()->with('i18n')->find(
array(
'condition' => 'gallery_id = :gal_id',
'order' => 'rand()',
'params' => array(
':gal_id' => $album->photo_gallery_id
)
));
}
$url = $this->createUrl('albumsSection/album', array('link' => $album->link,'node_id'=>Node::idByDataId('albumsSection',$album->albums_section_id)));
?>
getUrl('small'), $photo->i18n->name), $url)?>
i18n->name, $url);?>
clientScript;
$cs->registerCoreScript('jquery');
//$cs->registerScriptFile(Yii::app()->baseUrl . '/js/fancybox/jquery.mousewheel-3.0.4.pack.js');
$cs->registerScriptFile(Yii::app()->baseUrl . '/js/fancybox/jquery.fancybox-1.3.4.pack.js');
$cs->registerCssFile(Yii::app()->baseUrl . '/js/fancybox/jquery.fancybox-1.3.4.css');
$src = <<