Order Now AdSolution Sign Up | Login » Bits on the Run Sign Up | Login »

Forums

/

d-related not working locally

10 replies [Last post]

I have not been able to get JW Player 5.0 or 5.1 to recognize the d-related plugin when I try to load the plugin locally. I have made some changes to the d-related plugin source code that allows it to function better on my site. When I load the updated plugin in JW Player 4.6 it works perfectly, but when I try to use it with the new players the plugin is not recognized. As a test I tried loading an unmodified version of the plugin locally and the 5.0 and 5.1 players still do not load the plugin.
To be clear, I can access and use the plugin when I load it from the longtail servers using the 5.0 and 5.1 players, I simply cannot load it from my own server.
Any help?

 
Do you have a cross-domain policy file on the root of your domain?

I did not have one. I just added it and it did not make a difference. I am not getting any errors in my player, it is just acting like no plugin exists.
Here is a test page:
http://yotricks.com/wp-content/themes/videotheme11/flv/d-related%20plugin.html
The first player is 4.6 and the second is 5.1. In every way the code is identical but the second player will not load the plugin from my server like the first player does. If I load the plugin from the longtail servers using this code both players work perfectly.
My crossdomain.xml file is at http://yotricks.com/crossdomain.xml

 
Your cross-domain policy file is invalid.

You need to replace "yoursite" with the actual domain of your site or use one of the wildcard characters.

<?xml version="1.0"?>
<!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
<cross-domain-policy>
  <allow-access-from domain="www.<strong>yoursite</strong>.com" />
  <allow-access-from domain="<strong>yoursite</strong>.com" />
</cross-domain-policy>

Also, the v5 player requires the ".swf" extension on plugins and skins:

s2.addVariable('plugins', 'http://yotricks.com/wp-content/themes/videotheme11/flv/d-related<strong>.swf</strong>');

Also, be VERY careful about using your domain name without the "www".

Many of your visitors may be coming from search engines with the URI of "http://www.yotricks.com/wp-content/themes/videotheme11/flv/d-related plugin.html" and then your relative path to the Flash movie will be:

http://www.yotricks.com/wp-content/themes/videotheme11/flv/player-licensed_51.swf

which is not the EXACT same domain as the URI that you are using for the plugin of:

http://yotricks.com/wp-content/themes/videotheme11/flv/d-related.swf

This will cause a same-domain security error in Flash.

Also, two or more players on the same page shuld have unique name/id attributes, so use something like "mpl1" and "mpl2".

Also, you don't need to load swfobject.js twice.

I believe I have done everything you said and I have updated my file but the 5.1 player is still not loading the plugin:
http://yotricks.com/wp-content/themes/videotheme11/flv/d-related%20plugin.html
Thanks for taking the time to help me sort this out.

 
WOW!

This has me really puzzled.

The drelated plugin works loaded from my server into a v5 player, but I can't get ti to work with your code.

I'm too tired tonight to sort it out, but I'll give it another go in the morning.

Meanwhile, you can see it working here:

    http://willswonders.myip.org:8074/player5/Simple_D-Related_v5.html

And not working (yet!) here:

    http://willswonders.myip.org:8074/player5/AdamB.html

Awesome! I'll see what I can do with your code and post an update tonight if I make any progress.

 
OH! Now I see what's wrong.

You've apparently changed the drelated flashvars names.

Now it works from my server:

    http://willswonders.myip.org:8074/player5/AdamB.html

So, you've just broken the plugin; that's all. Well, you will have to fix it, then it will work.

I have sorted out as much as I can and this is the result:
http://yotricks.com/wp-content/themes/videotheme11/flv/d-relatedplugin.html
As you can see I have the plugin loading into 5.1 now but it is not working right. I altered the drelated plugin code which is why the flashvars have different names. Everything works great in 4.6 but not in 5.1. Perhaps I will have to content myself with 4.6 because I am not sure how to debug the code to work with 5.1.
Thanks for getting me this far. I'll let you know if I get any further.

 
I written quite a few v4 and a few v5 plugins.

If you post your code for the drelated plugin, I might be able to help you sort it out (no promises or guarantees though :S).

Here is a link to the version I am currently using:
http://YoTricks.com/drelate_updated.zip

I got this code originally from here:
http://github.com/jawngee/JW-Player-DRelated-Plugin/tree/master

(BTW In the txt file associated with this page he explains why he changed the flashvars and why he felt that the plugin needed an outside update.)

I started using this new version of d-related because it allowed me to play the playlist files directly in the main player instead of simply linking to an external file.

However, when I tried this updated version it did not work for me. That's why I made further modifications that are reflected in my version. Unfortunately I made those changes a few months ago and I cannot recall what I did exactly. What I do know is that the only differences between these versions and the original d-related plugin are reflected in the RelatedVideo.as file. I never work with flash files so it was something of a miracle that I have even gotten it this far.

If you can make anything out of that mess more power to ya! Right now I am quite happy with how the plugin works with version 4.6 but it would be awesome if it could work the same in 5.1.