Advertisement

Using SqueezeBox method within jQuery code ?

For Joomla! 2.5 Coding related discussions, please use: http://groups.google.com/group/joomla-dev-general
Note: All 1.6, 1.7 and 3.5 releases have reached end of life and should be updated to 3.x.

Moderator: ooffick

Forum rules
Please use the mailing list here: http://groups.google.com/group/joomla-dev-general rather than this forum.
Locked
duddy67
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 229
Joined: Sun Jul 12, 2009 12:04 pm

Using SqueezeBox method within jQuery code ?

Post by duddy67 » Fri Sep 20, 2013 9:49 am

Hi,

In my component I often use the SqueezeBox Mootools method, and
since I've moved to jQuery I now use it like that:

Code: Select all

jQuery.noConflict();  

(function($) {

  ...
 
  $.fn.openIntoIframe = function(link)
  {
    SqueezeBox.open(link, {handler: 'iframe', size: {x: 800, y: 530}});
    return this;
  };

  ...

})(jQuery);
It does work but I'm a bit puzzled about that.
Since SqueezeBox is a Mootools method is there any risk of conflict here (namespace for instance) ?
Is it safe to use it like this or is there another way to do that ?

Thanks for your answers.

Advertisement
User avatar
stutteringp0et
Joomla! Ace
Joomla! Ace
Posts: 1496
Joined: Sat Oct 28, 2006 11:16 pm
Location: Texas
Contact:

Re: Using SqueezeBox method within jQuery code ?

Post by stutteringp0et » Sat Dec 28, 2013 7:54 pm

If you're doing this in Joomla 3.x - then your mootools-more is missing the Hash functions.

After a little research, Gavern discovered this and put together an ultra-minimal mootools more that contains only Hash - so you can load it right before loading behavior.modal and everything works fine.

https://github.com/GavickPro/Meet-Gaver ... js/hash.js
64 Free RicheyWeb Extensions: https://extensions.joomla.org/profile/p ... ils/18398/
Custom Extension Development: https://www.richeyweb.com/contact-us

duddy67
Joomla! Enthusiast
Joomla! Enthusiast
Posts: 229
Joined: Sun Jul 12, 2009 12:04 pm

Re: Using SqueezeBox method within jQuery code ?

Post by duddy67 » Sun Dec 29, 2013 7:43 am

Thanks for your response.

No I don't plan to do this with Joomla 3 as I'll probably make it work differently.

However I didn't see any SqueezeBox method in the Gavern script.
I'm not even sure it will fix the pb under Joomla 3.

User avatar
stutteringp0et
Joomla! Ace
Joomla! Ace
Posts: 1496
Joined: Sat Oct 28, 2006 11:16 pm
Location: Texas
Contact:

Re: Using SqueezeBox method within jQuery code ?

Post by stutteringp0et » Sun Dec 29, 2013 8:25 pm

The Gavern script doesn't do anything for squeezebox, it replaces the missing MooTools-More Hash methods which Squeezebox relies on.
64 Free RicheyWeb Extensions: https://extensions.joomla.org/profile/p ... ils/18398/
Custom Extension Development: https://www.richeyweb.com/contact-us

Advertisement

Locked

Return to “Joomla! 2.5 Coding”