can't get JwPlayer to play from Rackspace CDN -
update
- it appear "direct/download url" rackspace works!
- but, "stream url", worked floplayer, not work jwplayer!?
i can images load, can urls come post ajax fine. cant working except video. no clue what's wrong honestly.
head
<script type="text/javascript" src="js/jquery-1.9.1.js"></script> <script type="text/javascript" src="js/jquery-ui-1.10.3.custom.min.js"></script> <script type="text/javascript" src="js/jdplugs.js"></script> // personal lib (jquery extendor) <script type="text/javascript" src="js/jwplayer/jwplayer.js"></script> <script type="text/javascript">jwplayer.key="";</script>
js (full)
var rackcdn = "http:// rackspace cloud link .com"; (function($) { if (!$.jwplayer) { $.extend({ jwplayer: function(elm, command, args) { if ($.jwplayer.methods[arguments[0]]) return $.jwplayer.methods[arguments[0]].apply(this, array.prototype.slice.call(arguments, 1)); if (typeof elm == "string") return jwplayer(elm); return jwplayer(elm.prop("id")); } }); $.jwplayer.methods = { load: function() { return jwplayer().load([arguments[0]]); }, play: function() { return jwplayer().play(); }, pause: function() { return jwplayer().pause(); } } } })(jquery); function liclick() { var key = $(this).data("key"), opts = { file: rackcdn+key, image: rackcdn+key }; console.log(opts); $.jwplayer("load", opts); } $(function() { $.jwplayer("testplayer01").setup({ file: "http:// rackspace cloud link .com/2013/03/20130303-message-service-hd.mp4", image: "http:// rackspace cloud link .com/video-stills/large/542.jpg", provider: "<?php echo(base_url('js/jwplayer/akamaiadvancedjwstreamprovider.swf')); ?>", height: "480", width: "600" }); $("li a").on("click", liclick); $("button").on("click", function(e) { $.jwplayer($.trim($(this).text())); }); $("h3").css({ cursor: "pointer" }).on("click", function(e) { $.getjson($.myurl("controllers/getlist.php"), function(data) { console.log(data) if ($.objlength(data) > 0) { $("ul").empty(); (x in data) { $("<li />").append($("<a />", { "data-key": data[x].name, href: "javascript:void(0)", text: data[x].name })).appendto($("ul")); } $("li a").on("click", liclick).first().click(); } }); }) })
js (focal point, think)
$.jwplayer("testplayer01").setup({ file: "http:// working link .mp4", image: "http:// working link .jpg", // link tested, file reside here provider: "<?php echo(base_url('js/jwplayer/akamaiadvancedjwstreamprovider.swf')); ?>", height: "480", width: "600" });
and yes have header includes , no i'm not getting console errors other jwerror, code 4.
mediaerror code: 4 __proto__: mediaerror media_err_aborted: 1 media_err_decode: 3 media_err_encrypted: 5 media_err_network: 2 media_err_src_not_supported: 4
Comments
Post a Comment