0

I have a page with a series of links to YouTube videos that display in a lightbox when clicked. I'm using prettyPhoto.

On the lightbox are share links - Facebook, Twitter, and such. Unfortunately the default behaviour of these share links is to share the whole page - I want to share the URL of the YouTube video specifically.

The HTML output is customisable, as a variable in the prettyPhoto JS, so I think what I need to do is take the URL you've just clicked on (which obviously PP knows, because it can play the video) and stick it in the share link.

I'm not great at JS, so hopefully this is a relatively simple thing! I'm even hoping PP has a variable somewhere in the code already that stores this info, and I can somehow just add it into the HTML variable... but don't know how!

Thanks :)

4

0 回答 0