Bug: imageview theme path not found

Everything to do with Templates and Templating for Admiror Gallery.
Post Reply
Message
Author
santilin
Posts: 6
Joined: Wed Feb 20, 2013 11:12 am

Bug: imageview theme path not found

#1 Post by santilin »

Hi, just installed AdmirorGallery extension and used the gallery template.

When viewed in my browser, I've got two errors:

"NetworkError: 404 Not Found - http://localhost/webs/mueblescapel.es/w ... t/next.gif"
"NetworkError: 404 Not Found - http://localhost/webs/mueblescapel.es/w ... t/prev.gif"

The problem being in ../templates/galleryView/jquery.galleryview-2.1.1.js:

Code: Select all

			// Determine path between current page and plugin images
			// Scan script tags and look for path to GalleryView plugin
			$('script').each(function(i){
				var s = $(this);
				if(s.attr('src') && s.attr('src').match(/jquery\.galleryview/)){
					loader_path = s.attr('src').split('jquery.galleryview')[0];
					theme_path = s.attr('src').split('jquery.galleryview')[0]+'themes/';
				}
			});
theme_path and loader_path are undefined as there are no <SCRIPT src='....jquery.galleryview'> anywhere in the page code.

I have workarounded this by hard coding the paths:

Code: Select all

                        if( !theme_path ) {
                            loader_path = 'plugins/content/admirorgallery/admirorgallery/templates/galleryView/';
                            theme_path = loader_path + 'themes/';
                        }
Kind regards
--santilín

Admiror Gallery 5 - Fundraising Campaign

User avatar
Vasiljevski
Developer
Developer
Posts: 1258
Joined: Sat Aug 14, 2010 9:31 pm
Location: Novi Sad, Serbia
Contact:

Re: Bug: imageview theme path not found

#2 Post by Vasiljevski »

Hmm interesting find :)

Personally, I have never came across this kind of problem.

What browser do you use?

Better solution could be to define

Code: Select all

var loader_path = 'plugins/content/admirorgallery/admirorgallery/templates/galleryView/';
var theme_path = loader_path + 'themes/'; 
At the top of the jquery.galleryview-2.1.1.js file, along with the other variables.

This should be there at the first place, but maybe creator of galleryview missed it :)

I will update Admiror Gallery code with this improvement and add thanks to you :)
Help Admiror Gallery become even better,
give us a review on JED

User avatar
Vasiljevski
Developer
Developer
Posts: 1258
Joined: Sat Aug 14, 2010 9:31 pm
Location: Novi Sad, Serbia
Contact:

Re: Bug: imageview theme path not found

#3 Post by Vasiljevski »

Better solution for this problem can be found at : http://www.vasiljevski.com/forum/viewto ... =839#p3203
Help Admiror Gallery become even better,
give us a review on JED

Post Reply