Embed_videos: Moved JS to header, added DIV. Removed unused view.
This commit is contained in:
parent
78a4fbacea
commit
329799db33
@ -18,7 +18,7 @@
|
|||||||
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
|
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
|
||||||
*/
|
*/
|
||||||
class embed_videos_theme_Core {
|
class embed_videos_theme_Core {
|
||||||
static function photo_bottom($theme) {
|
static function head($theme) {
|
||||||
$item = $theme->item();
|
$item = $theme->item();
|
||||||
if ($item && $item->is_photo()) {
|
if ($item && $item->is_photo()) {
|
||||||
$embedded_video = ORM::factory("embedded_video")
|
$embedded_video = ORM::factory("embedded_video")
|
||||||
|
@ -20,8 +20,8 @@
|
|||||||
?>
|
?>
|
||||||
<? if (isset($embed_code)): ?>
|
<? if (isset($embed_code)): ?>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
//$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$("#g-photo").replaceWith("<?= $embed_code ?>");
|
$("#g-photo").replaceWith("<div id=\"g-movie\" class=\"ui-helper-clearfix\"><?= $embed_code ?></div>");
|
||||||
//});
|
});
|
||||||
</script>
|
</script>
|
||||||
<? endif ?>
|
<? endif ?>
|
@ -1,19 +0,0 @@
|
|||||||
<?php defined("SYSPATH") or die("No direct script access.") ?>
|
|
||||||
<div id="g-item">
|
|
||||||
<?= $theme->photo_top() ?>
|
|
||||||
|
|
||||||
<?= $theme->paginator() ?>
|
|
||||||
|
|
||||||
<div id="g-movie" class="ui-helper-clearfix">
|
|
||||||
<?= $theme->resize_top($item) ?>
|
|
||||||
<?= $embedded_video ?>
|
|
||||||
<?= $theme->resize_bottom($item) ?>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="g-info">
|
|
||||||
<h1><?= html::purify($item->title) ?></h1>
|
|
||||||
<div><?= nl2br(html::purify($item->description)) ?></div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<?= $theme->photo_bottom() ?>
|
|
||||||
</div>
|
|
Reference in New Issue
Block a user