Add javascript variable to javascript src?

fodao br

New Member
this may sound a bit noobish, but I'm trying to retrieve the video information for a YouTube video (I saw in some tutorial) basically here's the code \[code\] function youtubeFeedCallback1(data) { var s = ''; var k = ''; s += data.entry.title.$t; k += data.entry.media$group.media$thumbnail[2].url; vidtitle1=s vidthumb1=k } <script type="text/javascript" id="javaone" src='http://gdata.youtube.com/feeds/api/videos/'+vidid[0]+'?v=2&alt=json-in-script&callback=youtubeFeedCallback1' ></script>\[/code\]As you can see, I'm trying to insert the var "vidid[0]" in the src, which doesnt work. Now, I did do my homework, but when i set a new script attribute and set the new src tot that it still does not work. Can anyone help me here?
 
Back
Top