Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Jan 2008
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Help w/ padding or margin

    The content in the home page of one of my recent web sites (it uses a PHP script) looks alright, but when any of the topics is clicked, the content appears to the left.

    Here is the link.

    Can anyone help me in getting the content centered there?

    Thanks in advance.

  • #2
    Regular Coder
    Join Date
    Nov 2006
    Posts
    247
    Thanks
    13
    Thanked 26 Times in 24 Posts
    In the code below: Add the parts highlighted in yellow. It'll center the images and video, and move the line "Other videos by this author:" off the border giving it a 10px margin on the left so it looks cleaner, but wont center it. If you do want that line centered as well with the video, take out the bits in red font color.
    Code:
    		<div class="left">
    
    			<div class="content">
    
    				<div style="margin: 0 10px"><div style="text-align: center">
    				<br><b>Video scenes shots:</b><br><br><img src="http://img.youtube.com/vi/sYYM-OCTYnU/1.jpg">&nbsp;<img src="http://img.youtube.com/vi/sYYM-OCTYnU/2.jpg">&nbsp;<img src="http://img.youtube.com/vi/sYYM-OCTYnU/3.jpg"><br><br><b>Watch the video:</b><br><br><object height="350" width="425"><param name="movie" value="http://www.youtube.com/v/sYYM-OCTYnU"><param name="wmode" value="transparent"><embed src="http://www.youtube.com/v/sYYM-OCTYnU" type="application/x-shockwave-flash" wmode="transparent" height="350" width="425"></object><div><script type="text/javascript"><!--
    google_ad_client = "pub-1097062987503577";
    google_ad_width = 468;
    google_ad_height = 60;
    google_ad_format = "468x60_as";
    google_ad_type = "text_image";
    google_ad_channel = "";
    google_color_border = "7C6F5C";
    google_color_bg = "7C6F5C";
    google_color_link = "FFFFFF";
    google_color_text = "DCDACC";
    google_color_url = "441";
    google_ui_features = "rc:6";
    //-->
    </script>
    <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
    </script></div></div><br><br><b>Other videos by this author:</b><br><br>
    				</div>
    I hope that's what you wanted.

  • #3
    Senior Coder ahallicks's Avatar
    Join Date
    May 2006
    Location
    Lancaster, UK
    Posts
    1,134
    Thanks
    1
    Thanked 57 Times in 55 Posts
    I think you win the 'Most Validation Errors Award' for today with 231! And that's with a doctype in place, though why you use XHTML 1.1 I don't know... especially with that many errors I'm curious why you have put those two styles in divs when they could both have been added to .content, or to another div you had created for the page that listed the styles you needed?
    "write it for FireFox then hack it for IE."
    Quote Originally Posted by Mhtml View Post
    Domains are like women - all the good ones are taken unless you want one from some foreign country.
    Reputation is your friend

    Development & SEO Tools


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •