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
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.

Horizontal Website

  • 21-08-2011 11:50PM
    #1
    Registered Users, Registered Users 2 Posts: 1,784 ✭✭✭


    Hi all,

    I know this is something simple but I just can't seem to crack it. I want a horizontal web layout and the code is as below.

    
    #container
    {
    	position:relative;
    //	width:20000px;
    	height:500px;
    	border:solid blue 2px;
    }
    
    #post
    {
    float:left;
    white-space:nowrap;	
    }
    
    
    <div id="header">
    <h1>TitleTitleTitle</h1>
    <h2>Something | AnotherThing | Hello</h2>
    </div>
    
    <div id="container">
    
    <div id="post">
    <img src="http://farm7.static.flickr.com/6200/6062305807_6c8302b9f2.jpg"  alt="Dundalk Half-1_z.jpg" height= "400" />
    <h2>
    This is a title
    </h2>
    </div>
    
    <div id="post">
    <img src="http://farm7.static.flickr.com/6200/6062305807_6c8302b9f2.jpg"  alt="Dundalk Half-1_z.jpg" height= "400" />
    <h2>
    This is a title
    </h2>
    </div>
    
    </div>
    


    Basically, I want to horizontally display a row of images but the problem I'm having is that when an image hits the right hand side of the page, it gets wrapped and pushed to the next line.

    So I'd like to override this auto wrapping feature but I'm having no luck doing it.

    Any help? :)


Comments

Advertisement