Marty Walker Posted October 2, 2012 Share Posted October 2, 2012 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 More sharing options...
apeisa Posted October 2, 2012 Share Posted October 2, 2012 Doesn't work on FF/Win7 either. It seems to fail loading swfobject.js: Link to comment Share on other sites More sharing options...
vitor Posted October 2, 2012 Share Posted October 2, 2012 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 More sharing options...
Marty Walker Posted October 2, 2012 Author Share Posted October 2, 2012 Thank you both. @vitor I think those settings are just overrides. It might be that I'm working on a subdomain but I had to hard-code the path into the main .js file. Regards Marty Link to comment Share on other sites More sharing options...
diogo Posted October 2, 2012 Share Posted October 2, 2012 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 More sharing options...
Marty Walker Posted October 2, 2012 Author Share Posted October 2, 2012 Although my posts to this forum would suggest otherwise, I'm really not that clever. That's why. Can you expand on this please? Regards Marty Link to comment Share on other sites More sharing options...
diogo Posted October 2, 2012 Share Posted October 2, 2012 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 More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now