Page 1 of 1

Shadowbox problem

Posted: 04 Oct 2009, 11:03
by kindUp
Hi,
It,s my first post. Sorry for my english (i'm from Poland).

Does anyone have a problem with displaying shadowbox with this Plugin? Here is the solution:

Into file: plugins/content/phocagallery.php near line 358 (
I changed a few lines and this number line into my file is 358) you must replace window.onload function to window.addEvent:

orginal:

Code: Select all

if ( $libraries['pg-group-shadowbox']->value == 0 ) {
                        $document->addCustomTag('<script type="text/javascript">
			Shadowbox.loadSkin("classic", "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/skin");
			Shadowbox.loadLanguage("'.$sb_lang.'", "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/lang");
			Shadowbox.loadPlayer(["img"], "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/player");
			window.onload = function(){
			Shadowbox.init();
			}
			</script>');
					$library->setLibrary('pg-group-shadowbox', 1);
				}
new:

Code: Select all

if ( $libraries['pg-group-shadowbox']->value == 0 ) {
					$document->addCustomTag('<script type="text/javascript">
			Shadowbox.loadSkin("classic", "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/skin");
			Shadowbox.loadLanguage("'.$sb_lang.'", "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/lang");
			Shadowbox.loadPlayer(["img"], "'.JURI::base(true).'/components/com_phocagallery/assets/js/shadowbox/src/player");
			window.addEvent(\'domready\', function(){
                        Shadowbox.init()
                        });
			</script>');
					$library->setLibrary('pg-group-shadowbox', 1);
				}
good luck, kindUp

Re: Shadowbox problem

Posted: 05 Oct 2009, 15:19
by Jan
Hi, thank you for this information. Jan

Re: Shadowbox problem

Posted: 26 Nov 2009, 14:48
by dagofee
I just registred myself to let know that this fixed the issues in my case!
please consider to fix it in the next release
ciao