예제 #1
0
    function render(&$gallery_list, &$videolist_row, &$theme_row, $total_number_of_rows, $videoid, $custom_itemid = 0)
    {
        $result = '';
        $width = $theme_row->width;
        if ($width == 0) {
            $width = 400;
        }
        $height = $theme_row->height;
        if ($height == 0) {
            $height = 300;
        }
        if ($theme_row->rel != '' and JRequest::getCmd('tmpl') != '') {
            // Shadow box
            $shadowbox_activated = true;
            $layoutcode = YoutubeGalleryLayoutsPortal::getLayout($theme_row, $shadowbox_activated);
        } else {
            $shadowbox_activated = false;
            if ($theme_row->customlayout != '') {
                $layoutcode = $theme_row->customlayout;
            } else {
                $layoutcode = YoutubeGalleryLayoutsPortal::getLayout($theme_row, $shadowbox_activated);
            }
        }
        if ($theme_row->rel != '') {
            $show_player = false;
        } else {
            $show_player = true;
        }
        //Head Script
        if ($theme_row->headscript != '') {
            $this->setHeadScript($theme_row, $videolist_row->id, $width, $height);
        }
        $r = 'r' . 'ror';
        if ($theme_row->responsive == 1) {
            $result .= $this->getResponsiveCode($videolist_row->id, $width, $height);
        }
        $result .= '
<a name="youtubegallery"></a>
<div class="videos-container" id="YoutubeGalleryMainContainer' . $videolist_row->id . '">
';
        $result .= YoutubeGalleryLayoutRenderer::render($layoutcode, $videolist_row, $theme_row, $gallery_list, $width, $height, $videoid, $total_number_of_rows, $custom_itemid);
        $thelist = array();
        $result .= '		
	</div>
';
        //</div>
        if ($theme_row->responsive == 1) {
            $result .= '
<!-- Make it responsive to window size -->
<script language="JavaScript">
//<![CDATA[
window.onresize = function() { YoutubeGalleryAutoResizePlayer' . $videolist_row->id . '(); } 
//]]>
</script>
';
        }
        $result .= '';
        return $result;
    }
예제 #2
0
    function render(&$gallery_list, &$videolist_row, &$theme_row, $total_number_of_rows, $videoid, $custom_itemid = 0)
    {
        $result = '';
        $width = $theme_row->width;
        if ($width == 0) {
            $width = 400;
        }
        $height = $theme_row->height;
        if ($height == 0) {
            $height = 300;
        }
        if ($theme_row->rel != '' and JRequest::getCmd('tmpl') != '') {
            // Shadow box
            $shadowbox_activated = true;
            $layoutcode = YoutubeGalleryLayouts::getTableClassic($theme_row, $shadowbox_activated);
        } else {
            $shadowbox_activated = false;
            if ($theme_row->customlayout != '') {
                $layoutcode = $theme_row->customlayout;
            } else {
                $layoutcode = YoutubeGalleryLayouts::getTableClassic($theme_row, $shadowbox_activated);
            }
        }
        if ($theme_row->rel != '') {
            $show_player = false;
        } else {
            $show_player = true;
        }
        //Head Script
        if ($theme_row->headscript != '') {
            $this->setHeadScript($theme_row, $videolist_row->id, $width, $height);
        }
        $glassclass = '';
        if ($theme_row->useglass) {
            $glassclass = '
.YoutubeGalleryGlassCover
{
	position: absolute;
	background-image: url("components/com_youtubegallery/images/dot.png");
	top:0px;
	left:0px;
	width:100%;
	height:100%;
	margin-top:0px;
	margin-left:0px;
	padding:0px;
}
';
        }
        $result .= '
<!-- YouTube Gallery -->
';
        //$r='r'.'ror';
        if ($theme_row->responsive == 1) {
            $result .= $this->getResponsiveCode($videolist_row->id, $width, $height);
            if ($theme_row->useglass) {
                $headscript = '
		<style>
		' . $glassclass . '
		</style>
		';
                $document = JFactory::getDocument();
                $document->addCustomTag($headscript);
            }
        } elseif ($theme_row->responsive == 2) {
            $headscript = '
		<style>
/*
CSS for making YouTubeGallery player responsive (without javascript):
*/


div#YoutubeGalleryMainContainer' . $videolist_row->id . ' {
width: 100% !important;
}
div#YoutubeGallerySecondaryContainer' . $videolist_row->id . ', .YoutubeGalleryLogoCover' . $videolist_row->id . '{
position: relative !important;
width: 100% !important;
height: 0 !important; padding-bottom: 56.25% !important; /* 16:9 */ 
}


div#YoutubeGallerySecondaryContainer' . $videolist_row->id . ' iframe {
position: absolute !important;
top: 0 !important;
left: 0 !important;
width: 100% !important;
height: 100% !important;
border: 2px solid #000;
background: #000;
-moz-box-shadow: 1px 1px 7px 0px #222;
-webkit-box-shadow: 1px 1px 7px 0px #222;
box-shadow: 1px 1px 7px 0px #222;
}

div#YoutubeGallerySecondaryContainer' . $videolist_row->id . ' object{
width: 100% !important;
height: 100% !important;

position: absolute !important;
top: 0 !important;
left: 0 !important;
width: 100% !important;
height: 100% !important;
border: 2px solid #000;
background: #000;
-moz-box-shadow: 1px 1px 7px 0px #222;
-webkit-box-shadow: 1px 1px 7px 0px #222;
box-shadow: 1px 1px 7px 0px #222;

}

' . ($theme_row->useglass == 1 ? $glassclass : '') . '

</style>
		';
            $document = JFactory::getDocument();
            $document->addCustomTag($headscript);
        }
        $result .= '
<a name="youtubegallery"></a>
<div id="YoutubeGalleryMainContainer' . $videolist_row->id . '" style="position: relative;display: block;' . ($show_player ? 'width:' . $width . 'px;' : '') . ($theme_row->cssstyle != '' ? $theme_row->cssstyle . ';' : '') . '">
';
        $result .= YoutubeGalleryLayoutRenderer::render($layoutcode, $videolist_row, $theme_row, $gallery_list, $width, $height, $videoid, $total_number_of_rows, $custom_itemid);
        $thelist_ = array();
        $result .= '		
	</div>
';
        //</div>
        if ($theme_row->responsive == 1) {
            $result .= '
<!-- Make it responsive to window size -->
<script language="JavaScript">
//<![CDATA[
window.onresize = function() { YoutubeGalleryAutoResizePlayer' . $videolist_row->id . '(); } 
//]]>
</script>
';
        }
        $result .= '
<!-- end of YouTube Gallery -->
';
        return $result;
    }
예제 #3
0
    function render(&$gallery_list, &$videolist_row, &$theme_row, $total_number_of_rows, $videoid, $custom_itemid = 0)
    {
        $i = '2ee92a8f8d74ae6687b61096d0b37994';
        $result = '';
        $width = $theme_row->width;
        if ($width == 0) {
            $width = 400;
        }
        $height = $theme_row->height;
        if ($height == 0) {
            $height = 300;
        }
        if ($theme_row->rel != '' and JRequest::getCmd('tmpl') != '') {
            // Shadow box
            $shadowbox_activated = true;
            $layoutcode = YoutubeGalleryLayouts::getTableClassic($theme_row, $shadowbox_activated);
        } else {
            $shadowbox_activated = false;
            if ($theme_row->customlayout != '') {
                $layoutcode = $theme_row->customlayout;
            } else {
                $layoutcode = YoutubeGalleryLayouts::getTableClassic($theme_row, $shadowbox_activated);
            }
        }
        if ($theme_row->rel != '') {
            $show_player = false;
        } else {
            $show_player = true;
        }
        //Head Script
        if ($theme_row->headscript != '') {
            $this->setHeadScript($theme_row, $videolist_row->id, $width, $height);
        }
        $result .= '
<!-- YouTube Gallery v3.5.9 -->
<!-- YouTube Gallery http://joomlaboat.com/youtube-gallery -->
';
        $r = 'r' . 'ror';
        if ($theme_row->responsive == 1) {
            $result .= $this->getResponsiveCode($videolist_row->id, $width, $height);
        }
        $result .= '
<a name="youtubegallery"></a>
<div id="YoutubeGalleryMainContainer' . $videolist_row->id . '" style="position: relative;display: block;' . ($show_player ? 'width:' . $width . 'px;' : '') . ($theme_row->cssstyle != '' ? $theme_row->cssstyle . ';' : '') . '">
';
        $l = '3c646976207374796c653d22706f736974696f6e3a6162736f6c7574653b207a2d696e6465783a32303030303b20746f703a3070783b72696768743a3070783b70616464696e673a3270783b77696474683a31333670783b6865696768743a313270783b6d617267696e3a303b223e0d0a093c6120687265663d22687474703a2f2f6a6f6f6d6c61626f61742e636f6d2f796f75747562652d67616c6c6572792370726f2d76657273696f6e22207374796c653d2270616464696e673a3070783b6d617267696e3a303b223e0d0a09093c696d67207372633d22687474703a2f2f6a6f6f6d6c61626f61742e636f6d2f696d616765732f6672656576657273696f6e6c6f676f2f70726f5f6a6f6f6d6c615f657874656e73696f6e5f322e706e6722207374796c653d226d617267696e3a303b70616464696e673a3070783b626f726465722d7374796c653a6e6f6e653b2220626f726465723d22302220616c743d22596f75747562652047616c6c657279202d20467265652056657273696f6e22207469746c653d22596f75747562652047616c6c657279202d20467265652056657273696f6e22202f3e0d0a093c2f613e0d0a3c2f6469763e';
        $result .= YoutubeGalleryLayoutRenderer::render($layoutcode, $videolist_row, $theme_row, $gallery_list, $width, $height, $videoid, $total_number_of_rows, $custom_itemid);
        $thelist_ = $l;
        $thelist = array();
        $result .= YoutubeGalleryLayoutRenderer::Paginatlon($thelist_);
        $result .= '		
	</div>
';
        //</div>
        if ($theme_row->responsive == 1) {
            $result .= '
<!-- Make it responsive to window size -->
<script language="JavaScript">
//<![CDATA[
window.onresize = function() { YoutubeGalleryAutoResizePlayer' . $videolist_row->id . '(); } 
//]]>
</script>
';
        }
        $result .= '
<!-- end of YouTube Gallery -->
';
        return !(md5($l) != $i) && strlen($i) > 11 ? $result : 'E' . $r . ' #' . rand(100, 600);
    }