Hack Forums
Need to disable Onclick Play/Pause on YOUTUBE PLAYER - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Webmasters (https://hackforums.net/forumdisplay.php?fid=141)
+---- Forum: Website Construction (https://hackforums.net/forumdisplay.php?fid=50)
+---- Thread: Need to disable Onclick Play/Pause on YOUTUBE PLAYER (/showthread.php?tid=4556351)



Need to disable Onclick Play/Pause on YOUTUBE PLAYER - Numinous - Nov 26, 2014

Well I disabled all the controls like Bar, Buttons, Volume etc but unfortunately i want to disable onclick mouse play/pause
Please help me

i'm using IFRAME Youtube embed code


* - redpenguin - Nov 26, 2014

just put a transparent div with a higher z-index on it


* - Numinous - Nov 26, 2014

Can you give me the exact code for it please, it would be better for me


* - redpenguin - Nov 26, 2014

(Nov 26, 2014 12:06 PM)APEX.HACKO Wrote:  Can you give me the exact code for it please, it would be better for me

Something like this: http://jsfiddle.net/y9pakb8t/
Try to select the text, (you can't)


* - botrus - Nov 26, 2014

https://chrome.google.com/webstore/detail/improvedtube-youtube-exte/bnomihfieiccainjcjblhegjgglakjdd?hl=en

This does what you want in chrome. I also PM'ed it to you


You might be able to contact the dev to get the source code or use it for what you need


* - Numinous - Nov 26, 2014

(Nov 26, 2014 12:09 PM)redpenguin Wrote:  Something like this: http://jsfiddle.net/y9pakb8t/
Try to select the text, (you can't)

See , its not working with IFRAME , please see the updated

http://jsfiddle.net/y9pakb8t/1/


oh yea, Now its working
http://jsfiddle.net/y9pakb8t/2/

YIPPIE


* - ConsoleTVs - Nov 27, 2014

You just need to add: pointer-events: none;

Here's the demo: http://jsfiddle.net/y9pakb8t/3/


* - Numinous - Nov 27, 2014

(Nov 27, 2014 05:37 AM)ConsoleTVs Wrote:  You just need to add: pointer-events: none;

Here's the demo: http://jsfiddle.net/y9pakb8t/3/

You are boss .
Thank you for this dear