News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

How To Embed Youtube Videos

Started by deep16, January 03, 2015, 10:30:52 AM

Previous topic - Next topic

deep16

How To Embed Youtube videos with full screen option. i use ohara youtube embed but after embedding there is no option for playing video in full screen

mark87

Quote from: deep16 on January 03, 2015, 10:30:52 AM
How To Embed Youtube videos with full screen option. i use ohara youtube embed but after embedding there is no option for playing video in full screen

I use the Simple Audio Video Embedder mod without any issues http://custom.simplemachines.org/mods/index.php?mod=2681

deep16

but i am unable to watch video in full screen in any mod

Mortissimov

Open OharaYTEmbed.php and change line 26:

<iframe width="'. (empty($modSettings['OYTE_video_width']) ? '420' : $modSettings['OYTE_video_width']) .'" height="'. (empty($modSettings['OYTE_video_height']) ? '315' : $modSettings['OYTE_video_height']) .'" src="http://www.youtube.com/embed/$1" frameborder="0"></iframe>

to

<iframe width="'. (empty($modSettings['OYTE_video_width']) ? '420' : $modSettings['OYTE_video_width']) .'" height="'. (empty($modSettings['OYTE_video_height']) ? '315' : $modSettings['OYTE_video_height']) .'" src="http://www.youtube.com/embed/$1" frameborder="0" allowfullscreen></iframe>

and line 47:

<iframe width="'. (empty($modSettings['OYTE_video_width']) ? '420' : $modSettings['OYTE_video_width']) .'" height="'. (empty($modSettings['OYTE_video_height']) ? '315' : $modSettings['OYTE_video_height']) .'" src="http://www.youtube.com/embed/$1" frameborder="0"></iframe>

to

<iframe width="'. (empty($modSettings['OYTE_video_width']) ? '420' : $modSettings['OYTE_video_width']) .'" height="'. (empty($modSettings['OYTE_video_height']) ? '315' : $modSettings['OYTE_video_height']) .'" src="http://www.youtube.com/embed/$1" frameborder="0" allowfullscreen></iframe>

It should work I think. allowfullscreen tag missing from code.

Advertisement: