Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi all,
Vanilla are planning an update to the site on April 24th (next Wednesday). It is a major PHP8 update which is expected to boost performance across the site. The site will be down from 7pm and it is expected to take about an hour to complete. We appreciate your patience during the update.
Thanks all.

Center Youtube Videos

  • 11-11-2014 6:28pm
    #1
    Registered Users Posts: 8,695 ✭✭✭


    Lads just wondering if anybody could help me with centering a youtube video using HTML. It's my first time trying to create a website for a college project and i am struggling to center the videos if anybody could help.

    I am just copying and pasting the embed code from the video from youtube for an example <iframe width="560" height="315" src="http://www.youtube.com/embed/5R1snVxGNVs&quot; frameborder="0" allowfullscreen></iframe>

    But i have no idea how to center that in the page or maybe it is not possible if anybody can advise.


Comments

  • Moderators, Education Moderators, Technology & Internet Moderators Posts: 2,588 Mod ✭✭✭✭KonFusion


    Try adding your page/code/css to codepen or jsfiddle so we can see what you've got so far


  • Closed Accounts Posts: 34,809 ✭✭✭✭smash


    iframe {margin:0 auto;}


Advertisement