Jump to content

UbaPlayer help


Marty Walker
 Share

Recommended Posts

Hi everyone,

I'm not if this is a PW problem or not so bear with me.

I've got UbaPlayer working nicely with PW on a project. So far i works well on Safari Mac but I'm having an issue with getting it working right on Mac Firefox. I test up a 2 tests pages with the same code.

First is the UberPlayer demo: http://d2b.clientsite2.net.au/ubaplayer/ - works on Mac Safari and FF.

... and this is the same code sitting in a PW template: http://d2b.clientsite2.net.au/test/ - works on Mac Safari but NOT FF.

I can't work out why. If anyone has the slightest clue I'd be very grateful.

Regards

Marty

Link to comment
Share on other sites

This is the correct code from: http://jsfiddle.net/brianhadaway/2xrf6/4/light/

$("#ubaPlayer").ubaPlayer({
   volume: 0.1,
   swfObjectPath: "http://brianhadaway.com/audio/js/swfobject.js",
   flashAudioPlayerPath: "http://www.brianhadaway.com/audio/swf/player.swf"
});

You have this:

$("#ubaPlayer").ubaPlayer({
codecs: [{name:"MP3", codec: 'audio/mpeg;'}]
});
Link to comment
Share on other sites

instead of hardcoding the url, why don't you define it on a script before linking to the main.js?

<script>var myUrl = "<?php echo $pages->get('mypage')->url";</script>
Link to comment
Share on other sites

:D

It's quite simple. If you create a variable in a script tag it will be available to any js file that is called after it. This just allows you to use php, thus, making it dynamic. This will apply to anything that you need to be dynamic and want use with js,

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...