From: Steve Sutton Date: Tue, 19 Aug 2014 14:11:51 +0000 (-0400) Subject: replace colorbox with fancybox X-Git-Tag: V1.0^2~35 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=ac703d0a5b51f26bb718ba110815418f0bf8b022;p=web%2FKeweenaw.git replace colorbox with fancybox Color box not working with newer version of jquery. --- diff --git a/Toolkit/Videos/VideosDataGrid.php b/Toolkit/Videos/VideosDataGrid.php index f2403e8..f9c5c93 100644 --- a/Toolkit/Videos/VideosDataGrid.php +++ b/Toolkit/Videos/VideosDataGrid.php @@ -212,7 +212,7 @@ class Toolkit_Videos_VideosDataGrid $vidCode = $match[1]; } $thumb = ($vidCode) - ? '' + ? '' : ''; return $thumb; } @@ -289,9 +289,9 @@ class Toolkit_Videos_VideosDataGrid $GLOBALS['styleSheets'][] = MEDIA_BASE_URL . 'Toolkit/Videos/styles.css'; $GLOBALS['styleSheets'][] - = MEDIA_APP_BASE_URL . 'gallery/colorbox/colorbox.css'; - $GLOBALS['bottomScripts'][] - = MEDIA_APP_BASE_URL . 'libjs/plugins/colorbox/1.3.15/jquery.colorbox-min.js'; + = MEDIA_BASE_URL . 'fancybox/jquery.fancybox.css'; + $GLOBALS['topScripts'][] + = MEDIA_BASE_URL . 'fancybox/jquery.fancybox.js'; $GLOBALS['bottomScripts'][] = MEDIA_BASE_URL . 'Toolkit/Videos/libjs/videos.js'; return parent::toHTML(); diff --git a/Toolkit/Videos/WebPageDecorator.php b/Toolkit/Videos/WebPageDecorator.php index 689f220..3a9cd6c 100644 --- a/Toolkit/Videos/WebPageDecorator.php +++ b/Toolkit/Videos/WebPageDecorator.php @@ -53,10 +53,8 @@ class Toolkit_Videos_WebPageDecorator implements Toolkit_Videos_IDecorator PDO $dbh, $gateway = null ) { - $GLOBALS['styleSheets'][] - = MEDIA_APP_BASE_URL . 'gallery/colorbox/colorbox.css'; $GLOBALS['bottomScripts'][] - = MEDIA_APP_BASE_URL . 'libjs/plugins/colorbox/1.3.15/jquery.colorbox-min.js'; + = MEDIA_BASE_URL . 'fancybox/jquery.fancybox.js'; $GLOBALS['bottomScripts'][] = MEDIA_BASE_URL . 'Toolkit/Videos/libjs/videos.js'; $dbh = Toolkit_Database::getInstance(); diff --git a/Toolkit/Videos/libjs/videos.js b/Toolkit/Videos/libjs/videos.js index aa764e6..600df7f 100644 --- a/Toolkit/Videos/libjs/videos.js +++ b/Toolkit/Videos/libjs/videos.js @@ -1,12 +1,11 @@ var GLMColorBox = { init: function() { - var width = $(window).width() * .85; + var width = $(window).width() * .85; var height = $(window).height() * .8; - //$('a.colorbox').colorbox({iframe: true, innerWidth:425, innerHeight:344}); - $('select.posSelect').each(function () { - $(this).change(function(){ + $('select.posSelect').each(function() { + $(this).change(function() { var id = $(this).attr('rel'); - var newpos = $(this).attr('value'); + var newpos = $(this).prop('value'); window.location.href = '../video-move/' + id + '/' + newpos + '/'; }); }); @@ -16,15 +15,15 @@ var GLMColorBox = { $(document).ready(GLMColorBox.init); $(document).ready(function() { - $(".various").fancybox({ - maxWidth : 1200, - maxHeight : 800, - fitToView : false, - width : '100%', - height : '100%', - autoSize : false, - closeClick : false, - openEffect : 'none', - closeEffect : 'none' - }); + $(".various").fancybox({ + maxWidth: 1200, + maxHeight: 800, + fitToView: false, + width: '100%', + height: '100%', + autoSize: false, + closeClick: false, + openEffect: 'none', + closeEffect: 'none' + }); });