jquery - Make Dailymotion videos work with Prettyphoto -


after lot of searching i've found here changes should done in order dailymotion videos should work prettyphoto.

i've done these changes , it's working... not first time after refresh page.

i mean if have rel="prettyphoto[videos]" , here have 3 videos youtube, vimeo , dailymotion, it's working if don't hit first time dailymotion video. if hit vimeo video , going next video...it's working. if refresh page , hit dailymotion video first... it's not working.

i'm sure minor change because doesn't recognize path first time or don't know...

a live example here.

the code added this:

 case 'dailymotion':     correctsizes = _fittoviewport(movie_width,movie_height); // fit item viewport     // remove url's beginning     var videoid = pp_images[set_position].replace(/http:\/\/www\.dailymotion\.com\/video\//i, '');     // "explode" end of string catch video id     var spt = videoid.split('_');     // video id index 0     movie = 'http://www.dailymotion.com/swf/' + spt[0] + '?width=&theme=none&iframe=0&additionalinfos=0&autoplay=1&hideinfos=0';     toinject =  settings.iframe_markup.replace(/{width}/g,correctsizes['width']).replace(/{height}/g,correctsizes['height']).replace(/{wmode}/g,settings.wmode).replace(/{path}/g,movie); break;  

and, yes found casar davorin's script dailymotion doesn't work, if says working.

could me please?

thanks in advice.

i had same problem , solution quite simple, replace correctsizes pp_dimensions.

i've found solution of firebug. if use firefox, , not have installed, recommend install it. =)


Comments

Popular posts from this blog

objective c - Change font of selected text in UITextView -

php - Accessing POST data in Facebook cavas app -

c# - Getting control value when switching a view as part of a multiview -