youtube url is not working in javascript,why?
where is the mistake in my code:
$(document).ready(function(){
api_images = ['http://www.youtube.com/watchv=OyQoHmcunk&rel=0&fs=0&width=640&height=360'];
api_titles = ['Title 1'];
api_descriptions = ['']
$.prettyPhoto.open(api_images,api_titles,api_descriptions);
});
You’re missing the
?that actually separates the path from the query-string:Without it, you should be receiving a 404 response, which a decent javascript debugger would’ve told you. You are using a debugger, right?
Also, depending on the
DOCTYPEin use and whether this is from an inline or external<script>, HTML-encoding the&s may either be necessary or another source of issue: