[Solved] Showtime and Gallery not working on same page

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
Shaolin
Forum Members
Forum Members
Posts: 16
Joined: Wed Aug 22, 2012 3:44 pm

[Solved] Showtime and Gallery not working on same page

Post by Shaolin »

Hi,

I have been getting familiar with CMSMS over the past couple of weeks. I am designing locally on my PC with a fresh install of the latest XAMPP and the latest CMSMS.

I have my website pretty much the way I want it but I have come across a hurdle in that on a couple of pages I would like to use both the showtime module and the Gallery module. This is where I fall down.

With the showtime module I am using the NivoSlider setting and this showtime module appears on all pages at the top of the content block. I would like the gallery module to appear on a few select pages underneath the Showtime NivoSlider but when I add the gallery tag underneath the showtime tag, the gallery loads fine but the showtime module just has the circular "loading" icon.

When I load a page which does not have the gallery module but does have the showtime module, the showtime module is working fine. To recap:

Showtime on its own = fine
Showtime + Gallery = showtime not loading & Gallery fine

Incidentally, changing showtime from Nivoslider to JQuery eradicates the problem but this is not my ideal solution as I really would like to use the NivoSilder for Showtime.

Any help or assistance would be very much appreciated

Kindest regards

Shaolin
Last edited by Shaolin on Mon Sep 17, 2012 6:17 pm, edited 2 times in total.
Jos
Support Guru
Support Guru
Posts: 4020
Joined: Wed Sep 05, 2007 8:03 pm

Re: Showtime and Gallery not working together on same page

Post by Jos »

Check your html sourcecode if the jQuery library is called more than once. Both Gallery and Showtime add it automatically by default.
In your case I guess it is easiest is to disable it on both and add the jQuery call in the global settings metadata field.
Shaolin
Forum Members
Forum Members
Posts: 16
Joined: Wed Aug 22, 2012 3:44 pm

Re: Showtime and Gallery not working together on same page

Post by Shaolin »

Hi,

Thanks for your help. I have looked at my html sourcecode and cant find any reference to JQuery. Could you please explain the process you are talking about regarding adding the jQuery call in the global settings metadata field. How exactly would i go about doing that. I was of the understanding that I was not using JQuery for the showtime module, I was using the Nivoslider option.

As i said I am only just starting to get to grips with CMSMS.

Kind regards

Shaolin
Shaolin
Forum Members
Forum Members
Posts: 16
Joined: Wed Aug 22, 2012 3:44 pm

Re: Showtime and Gallery not working together on same page

Post by Shaolin »

Sorry, I just realised what you meant. I was looking at my template, there is no JQuery in the template but obviously there wouldn't be. In the source code of the website JQuery is indeed called twice, once for show time and once for gallery, so do I simply copy both of these JQuery calls (4 lines of code) in the global metadata field? Sorry for asking for an idiots guide here.

Kind regards

Shaolin
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Showtime and Gallery not working together on same page

Post by Dr.CSS »

Most times it has to do with the core jQuery script being called twice, once for each module, or the version of the jquery script, if it's being called twice, you will see it in the page source, then remove it from the Gallery template to see if it works...
Shaolin
Forum Members
Forum Members
Posts: 16
Joined: Wed Aug 22, 2012 3:44 pm

Re: Showtime and Gallery not working together on same page

Post by Shaolin »

That did the trick, removing the jQuery line from the gallery template.

Many thanks

Shaolin
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Contact:

Re: Showtime and Gallery not working together on same page

Post by paulbaker »

Thanks guys! Just had exactly the same problem and this thread solved it for me. (Shaolin can you change the subject of the first post and add "[solved] " to the front?)

Thanks again 8)
Shaolin
Forum Members
Forum Members
Posts: 16
Joined: Wed Aug 22, 2012 3:44 pm

Re: [Solved] Showtime and Gallery not working on same page

Post by Shaolin »

Added [solved] as requested. Sorry, I'm new to CMSMS and these forums, will adhere to this regime in future.
stevegos

Re: [Solved] Showtime and Gallery not working on same page

Post by stevegos »

Hi

I have the same problem and have followed the instructions but its not fixed my problem. Here's a copy of the original output html:

Code: Select all

<!-- Gallery/Fancybox -->
<link rel="stylesheet" href="http://www.domain.co.uk/new2/modules/Gallery/templates/css/Fancybox.css" type="text/css" media="screen" />
<!-- <__script__ type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></__script> -->
<__script__ type="text/javascript" src="modules/Gallery/templates/fancybox/jquery.fancybox.pack.js"></__script>
<__script__ type="text/javascript" src="modules/Gallery/lib/jquery/jquery.mousewheel.pack.js"></__script>

<__script__ type="text/javascript">
$(document).ready(function() {
	$("a.group").fancybox({
		'speedIn':		300,
		'speedOut':	300,
		'overlayColor':	'#000',
		'overlayOpacity':	0.7
	});
});
</__script>


<!--css for show1-->
<link rel="stylesheet" type="text/css" href="http://www.domain.co.uk/new2/modules/Showtime/templates/css/Show_1.css" />
<!--LOAD SHOWTIME jQuery-->
<__script__ type="text/javascript" src="http://www.domain.co.uk/new2/modules/Showtime/templates/jquery/jquery-1.4.2.js" ></__script>
<__script__ type="text/javascript" src="http://www.domain.co.uk/new2/modules/Showtime/templates/jquery/jquery.cycle.all.min.js" ></__script>
<!--END SHOWTIME-->
I tried removing the jquery call from the fancybox gallery template but it still does not work. I tried unticking the load jquery in showtime and did not work either.

All help greatly appreciated.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: [Solved] Showtime and Gallery not working on same page

Post by Dr.CSS »

Depending on where the jquery call is called first will depend on where you remove it, it looks like it is called in Gallery first so you will need to remove it from the Showtime template, it needs to be called before any other scripts that depend on it...
Post Reply

Return to “Modules/Add-Ons”