+ Start a Discussion

How to calculate if src in iframe is clicked or not


I am using iframe to show youtube embedded video on visualforce page. I want to capture if the video is played or not.
Please help me to write onclick function or any other way to capture the click on video.

Sujit Anil NirkheSujit Anil Nirkhe

Rather than capturing click on iframe(ex. if you tube is blocked by proxy, and some one clicks on iframe...this scenario will fail), you should try to capture iframe status related to playing video.

You can give this a try : http://stackoverflow.com/questions/8950146/check-if-youtube-video-is-playing-and-run-script

thanks sujit.
but i am not only embedding youtube video, i m also embedding box.net  videos
kindly advice for this scenario