Results 1 to 3 of 3

Thread: View Special DIVS

  1. #1
    Join Date
    May 2010
    Posts
    10
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Default View Special DIVS

    Hi everyone
    My DIV are shown below
    Click image for larger version. 

Name:	1.jpg 
Views:	162 
Size:	7.9 KB 
ID:	5808
    I want them to be shown as follows:
    Click image for larger version. 

Name:	2.jpg 
Views:	153 
Size:	7.7 KB 
ID:	5809

  2. #2
    Join Date
    Nov 2014
    Location
    On A Scottish Island
    Posts
    488
    Thanks
    0
    Thanked 62 Times in 58 Posts

    Default

    Have a look at this thread first.

  3. #3
    Join Date
    Nov 2006
    Location
    chertsey, a small town 25 miles south west of london, england.
    Posts
    1,920
    Thanks
    2
    Thanked 267 Times in 262 Posts

    Default

    Hi there mostafa_dadgar,

    try it like this...

    Code:
    
    <!DOCTYPE html>
    <html  lang="en">
    <head>
    
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    
    <title>divvy stuff</title>
    
    <style media="screen">
    body {
        background-color:#f0f0f0;
     }   
    #container {
        width:394px;
        padding:8px 8px 0;
        margin:auto;
        border:1px solid #999;
        border-radius:10px;
        background-color:#fff;
        box-shadow:10px 10px 10px #999;
        overflow:hidden;
     }
    .columns {
        float:left;
        width:126px;
     }
    .margin {
        margin:0 8px;
     }
    .columns div {
        border:1px solid #666;
        border-radius:8px;
        margin-bottom:8px;
        box-sizing:border-box;
        background:#ccc; 
        box-shadow:inset 0 0 20px #666;
     } 
    .sixty {
        height:60px;
     }
    .sixtyfive {
        height:65px;
     }
    .ninety {
        height:90px;
     }
    .onefifty {
        height:150px;
     }
    @media screen and (max-width:452px) {
    #container {
        width:260px;
      }
    #container div:nth-child(3) {
        clear:left;
      }
    .margin {
        margin:0 0 0 8px;
      } 
     }
    @media screen and (max-width:324px) {
    #container {
        width:126px;
      }
    #container div:nth-child(2) {
        clear:left;
     }
    .margin {
        margin:0;
      }
     }
    </style>
    
    </head>
    <body>
    
    <div id="container">
    
    <div class="columns">
     <div class="ninety"></div>
     <div class="onefifty"></div>
     <div class="onefifty"></div>
    </div>
    
    <div class="columns margin">
     <div class="onefifty"></div>
     <div class="onefifty"></div>
     <div class="sixtyfive"></div>
    </div>
    
    <div class="columns">
     <div class="onefifty"></div>
     <div class="sixty"></div>
     <div class="onefifty"></div>
    </div>
    
    </div><!-- end #container -->
    
    </body>
    </html>

    coothead
    ~ the original bald headed old fart ~

  4. The Following User Says Thank You to coothead For This Useful Post:

    mostafa_dadgar (01-25-2016)

Similar Threads

  1. Iframe-divs: a technique for letting divs overlay anything we want
    By molendijk in forum Submit a DHTML or CSS code
    Replies: 0
    Last Post: 03-22-2012, 08:30 PM
  2. "Floating" divs that scroll with page, with special conditions.
    By prototism in forum Looking for such a script or service
    Replies: 6
    Last Post: 08-29-2010, 10:14 PM
  3. Replies: 1
    Last Post: 03-10-2010, 01:10 AM
  4. Animated Collapsible DIVS -additional DIVS float aside 3rd DIV
    By jono in forum Dynamic Drive scripts help
    Replies: 2
    Last Post: 05-12-2009, 12:57 PM
  5. Replies: 0
    Last Post: 10-12-2008, 08:20 PM

Bookmarks

Posting Permissions

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