Welcome, Guest
Please login or register
February 22, 2012, 10:34:43 PM
Topic: How to Add Youtube Video to player?  (Read 2931 times)
Author
How to Add Youtube Video to player?
Peter1980
*
Posts: 9

« on: May 20, 2010, 06:44:45 PM »

I want to be able to add youtube video to the player. How do I do this?

Also, when someone watches the youtube video on the player, does youtube count that as a "view"? Does it record it as a view?

Thanks.

Adrian.B
Global Moderator

*****
Posts: 262



« Reply #1 on: May 21, 2010, 01:36:54 AM »

In the settings.xml file, replace the video tag with one containing the path to a YouTube video.

Like this:

Code:
        <video>
<ad start="30" path="videos/ad.mp4" url="http://dsc.discovery.com/"/>
<videoPath value="http://www.youtube.com/watch?v=kIPGZs0UCQc" />
<title>
<![CDATA[What you write here overwrites the title on YouTube]]>
</title>
<description>
<![CDATA[What you write here overwrites the description on YouTube]]>
</description>
</video>

Yes it does count as viewed.

« Last Edit: May 21, 2010, 03:05:01 AM by Adrian.B »
tomekm
*
Posts: 14

« Reply #2 on: June 01, 2010, 03:16:13 PM »

Hi,

I'm developing site for Peter1980 and have got one problem with player and YT option. When I'm inserting YT video link in firebug I can see one failed request: http://gdata.youtube.com/swf/apiplayer.swf

This link is probably hard coded into swf, so is there some update for this or some possibility of updating this link from xml?

Regards,
Tomek


Adrian.B
Global Moderator

*****
Posts: 262



« Reply #3 on: June 02, 2010, 05:20:03 AM »

I believe you are testing it locally?

Adobe's Flash security settings: you need to go to:

http://www.macromedia.com/support/documentation/en/flashplayer/help/settings_manager04a.html

and add the folder where you have the swf to that list of trusted locations.

tomekm
*
Posts: 14

« Reply #4 on: June 02, 2010, 05:07:18 PM »

No, same happens on server.
Image preview from youtube is loaded but when I hit play player stucks.
In FireBug I can see that last request is for that:
http://gdata.youtube.com/swf/apiplayer.swf
when I try to call it from browser there is 'not found' message

bnitica
Global Moderator

*****
Posts: 79



« Reply #5 on: June 02, 2010, 05:50:11 PM »

If you take a look, with Firebug, at our site on a page where is the player you'll that it loading http://www.youtube.com/apiplayer?version=3

It's for the first time when I hear about this issue.

Please provide me a link where to look at. Also be sure you have the last version of the player, maybe you have a very old AS2 version.

Regards

tomekm
*
Posts: 14

« Reply #6 on: June 06, 2010, 04:23:39 PM »

Hi,

this is an example:
http://shp.tomarshal.pl/listings/1802lakeshore
preview image is loaded, after clicking play player stucks.

Maybe this is problem with swf version, I've got player from Peter1980, he told me that this is the newest version.

Regards,
Tomek

« Last Edit: June 06, 2010, 04:39:29 PM by tomekm »
Peter - Icebear
Global Moderator

*****
Posts: 201

« Reply #7 on: June 07, 2010, 03:19:01 AM »

Hi,

If i try to check you XML file in the browser by your URL (from the source)
http://shp.tomarshal.pl/?pid=example%26type=xml%26id=22

I get an error. Thats why you have error. The link is not correct..

I believe it must be:
http://shp.tomarshal.pl/?pid=example&type=xml&id=22

Greetings Peter

"In the end, it's not going to matter how many breaths you took, but how many moments took your breath away"
tomekm
*
Posts: 14

« Reply #8 on: June 07, 2010, 05:27:10 AM »

Hi,

thanks for your reply but you're wrong.

Ampersands are converted to numeric coding because flash '&' symbol understands as divider of flashvars - in this case xml address is one variable so to bypass cuting this address into variables I have to replace '&' with numeric equivalent.
Moreover, when you check firebug you can see that xml is loaded (check response), otherwise image preview of YT movie should not be displayed (link to YT movie is passed via generated XML).

Regards,
Tomek

Adrian.B
Global Moderator

*****
Posts: 262



« Reply #9 on: June 07, 2010, 05:57:24 AM »

I see that you have a very old version of the swf. I have two suggestions:

1) redownload the swf. I'm not sure if I remember correctly the date when Peter1980 got the player, but I suspect it was before YouTube made their changes with the api.

2) test the player with a link to another video, not YT. And let us know what happens

tomekm
*
Posts: 14

« Reply #10 on: June 08, 2010, 02:24:03 AM »

Ad. 2 Player was tested with non YT videos (i.e. mov or flv) with that files it works fine.

Ad. 1 I've asked Peter1980 to download package again.

Thanks,
Tomek

Adrian.B
Global Moderator

*****
Posts: 262



« Reply #11 on: June 08, 2010, 04:03:52 AM »

Ok, let me know if you can make the YT videos work with the updated version. It should be just fine, just as the samples are working here on our server.

tomekm
*
Posts: 14

« Reply #12 on: June 09, 2010, 02:37:09 AM »

Peter told me that he didn't found place where he can download new package without purchasing it.
Can you post this swf here (downloadable) or mail me (tom.marszalek@gmail.com)?

Tomek

Peter - Icebear
Global Moderator

*****
Posts: 201

« Reply #13 on: June 09, 2010, 02:41:26 AM »

Hello Tomek,

It should be on the place where he downlaoded it the last time.
If he bought it here you can find it at the location:
Profile -> My Products -> there you should see the overview of the products

Greetings Peter

"In the end, it's not going to matter how many breaths you took, but how many moments took your breath away"
Adrian.B
Global Moderator

*****
Posts: 262



« Reply #14 on: June 09, 2010, 03:07:55 AM »

Indeed, thank you Peter.

Anyway, I have just sent the updated version to Peter1980 via email.

Pages: 1 2
 

Community

What's hot on the forums

Hi,

Is it possible in the near future for the possibility of pre-, mid- or post-rolling an ad for the video.
I have seen it on the lin...

News

Stay up to date

We've launched a new cool project called VisionFlow.

Like it? Share it!

Tell your friends about us

Do you like our products or our site? We would be very grateful if you shared them with your friends, colleagues, parents, pets and spread the word about our awesome products.

Share to Facebook Share to Twitter Stumble It Email This More Share...