1
0

Embed_videos: Moved JS to header, added DIV. Removed unused view.

This commit is contained in:
John Bowles 2010-08-27 17:00:18 -07:00
parent 78a4fbacea
commit 329799db33
3 changed files with 4 additions and 23 deletions

View File

@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class embed_videos_theme_Core {
static function photo_bottom($theme) {
static function head($theme) {
$item = $theme->item();
if ($item && $item->is_photo()) {
$embedded_video = ORM::factory("embedded_video")

View File

@ -20,8 +20,8 @@
?>
<? if (isset($embed_code)): ?>
<script type="text/javascript">
//$(document).ready(function() {
$("#g-photo").replaceWith("<?= $embed_code ?>");
//});
$(document).ready(function() {
$("#g-photo").replaceWith("<div id=\"g-movie\" class=\"ui-helper-clearfix\"><?= $embed_code ?></div>");
});
</script>
<? endif ?>

View File

@ -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>