Help with </div>

Results 1 to 3 of 3
  1. #1
    Loyalty Vaulient is offline
    MemberRank
    May 2012 Join Date
    MalaysiaLocation
    1,796Posts

    Help with </div>

    This is rather ... embarrassing to ask but I've been trying for like an hour now and I jsut can't get the </div>'s right for the page , it just shows up like this ...

    http://prntscr.com/3473x1

    Could someone help me fix this? , the code is this ..

    Code:
    <?php include('head.php'); ?>
                            <div id="subnavi-search-upper">
                                <ul id="subnavi-search-links">
    								<li><a href="{url}/logout" style="color:#000">Sign Out</a></li>
                                </ul>
                            </div>
                        </div>
                        <div id="to-hotel">
                            <a href="{url}/client" class="new-button green-button" target="eac955c8dbc88172421193892a3e98fc7402021a" onclick="HabboClient.openOrFocus(this); return false;"><b>Enter {hotelName}</b><i></i></a>
                        </div>
                    </div>
                    <ul id="navi">
                        <li class="metab selected"><strong>{username}</strong><span></span></li>
                        <li><a href="{url}/community">Community</a><span></span></li>
    					<li><a href="{url}/shop">Shop</a><span></span></li>
    					<li class="last"><a href="{url}/lb">Leaderboards</a><span></span></li>
                    </ul>
                    <div id="habbos-online"><div class="rounded"><span>{online} members online</span></div></div>
                </div>
            </div> <div id="content-container">
                <div id="navi2-container" class="pngbg">
                    <div id="navi2" class="pngbg clearfix">
                        <ul>
                            <li class="selected">Home</li>
                            <li class=""><a href="{url}/account">Account Settings</a></li>
    						                    </ul>
                    </div>
                </div>
            <div id="container">
                    <div id="content" style="position: relative" class="clearfix">
                        <div id="column1" class="column">
                            <div class="habblet-container ">		
                                <div id="new-personal-info" style="background-image:url({url}/app/tpl/skins/Habbo/images/personal_info/hotel_views/htlview_us.png)">
                                    <div class="enter-hotel-btn">
                                        <div class="open enter-btn">
                                            <a href="{url}/client" target="eac955c8dbc88172421193892a3e98fc7402021a" onclick="HabboClient.openOrFocus(this); return false;">Enter {hotelName} Hotel<i></i></a>
                                            <b></b>
                                        </div>
                                    </div>
                                    <div id="habbo-plate"><img src="http://www.habbo.nl/habbo-imaging/avatarimage?figure={figure}" alt="{username}"></div>
                                    <div id="habbo-info">
                                        <div id="motto-container" class="clearfix">			
                                            <strong>{username}:</strong>
                                            <div>
                                                <span title="What's on your mind today?">{motto}</span>
                                            </div>
                                        </div>
                                        <div id="motto-links" style="display: none"><a href="#" id="motto-cancel">Cancel</a></div>
                                    </div>
                                    <ul id="link-bar" class="clearfix">		
                                       
                                    </ul>
                                    <div id="habbo-feed">
                                        <ul id="feed-items">
    										<li>Hello <b>{username}</b>. {hotelname} is still new, so may not have the best user count at times.. - If you find any bugs, or need help <a href="{url}/help">Click here!</a></li>
    									</ul>
                                  
    								</div>
                                    <p class="last"></p>
                                </div>
    							
                                <script type="text/javascript">
                                    HabboView.add(function() {
                                        L10N.put("personal_info.motto_editor.spamming", "Don\'t spam me, bro!");
                                        PersonalInfo.init("");
                                    });
                                </script>
     
    <div>
    </div>      
                
    
    
                    </div>
    				</div>
    				</div>
    <div class="habblet-container " style="width:460px"> 
         <div class="cbb clearfix brown ">                                 
    	<h2 class="title">Radio</h2>                                 
    	<div style="padding:5px"> 
               <center><script type="text/javascript" src="http://shoutcast.mixstream.net/js/song/uk2-free:19116">
    You appear to have javascript turned off.
    </script><script type="text/javascript" src="http://player.wavestreamer.com/cgi-bin/swf.js?id=66PS7C9N6WZDSHLK"></script>
    <script type="text/javascript" src=" http://player.wavestreaming.com/?id=66PS7C9N6WZDSHLK"></script>
    
    </div></center>
    						<div id="column1" class="column">
    								<div class="cbb clearfix red">
    									<h2 class="title"><font size="1">Hot Campaigns</font></h2>
    									<div id="hotcampaigns-habblet-list-container">
    									<p style="padding: 7px 7px 1px;">
    									                                <?php
        $campaign = mysql_query("SELECT * FROM cms_campaigns ORDER BY `id` DESC"); // Query, Select data from cms_camps..
        if(mysql_num_rows($campaign) == 0){
            echo 'MAKE A CAMPAIGN TO FIX ME!!!'; // No campaigns? This will show.
        }
     
            while($row = mysql_fetch_array($campaign)){ // Fetch shit from $camps..
     
                // Start variables
                $id = $row["id"];
                $caption = $row["caption"];
                $image_url = $row["image_url"];
                $description = $row["description"];
                $url = $row["url"];
                // End variables
       
                echo '<ul id="hotcampaigns-habblet-list">
                      <li class="even">
                      <a href="'.$url.'">
                      <img src="'.$image_url.'" align="left" alt="'.$caption.'" /></a>
                      <h3>'.$caption.'</h3>
                      <p>'.$description.'</p>
                      <p class="link"><a href="'.$url.'">Go there &raquo;</a></p>
                      </li> </ul>
                            ';
        }
        ?>
            
    									</p>
    					            </div></div>
    
    
                        <div id="column2" class="column">
                            <div class="habblet-container "></div>
                            <script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
                            <div class="habblet-container news-promo">		
                                <div class="cbb clearfix notitle ">
                                    <div id="newspromo">
                                        <div id="topstories">
                                            <div class="topstory" style="background-image: url({url}/r63/c_images/Top_Story_Images/{newsIMG-1})">
                                                <h4>Latest news</h4>
                                                <h3><a href="{url}/index.php?url=news&id={newsID-1}">{newsTitle-1}</a></h3>
                                                <p class="summary">
                                                    {newsCaption-1}
                                                </p>
                                                <p>
                                                    <a href="{url}/index.php?url=news&id={newsID-1}">Read more &raquo;</a>
                                                </p>
                                            </div>
                                            <div class="topstory" style="background-image: url({url}/r63/c_images/Top_Story_Images/{newsIMG-2}); display: none">
                                                <h4>Latest news</h4>
                                                <h3><a href="{url}/index.php?url=news&id={newsID-2}">{newsTitle-2}</a></h3>
                                                <p class="summary">
                                                    {newsCaption-2}
                                                </p>
                                                <p>
                                                    <a href="{url}/index.php?url=news&id={newsID-2}">Read more &raquo;</a>
                                                </p>
                                            </div>
                                            <div id="topstories-nav" style="display: none"><a href="#" class="prev">&laquo; Previous</a><span>1</span> / 3<a href="#" class="next">Next &raquo;</a></div>
                                        </div>
                                        <ul class="widelist">
                                            <li class="even"><a href="{url}/index.php?url=news&id={newsID-1}">{newsTitle-1} &raquo;</a><div class="newsitem-date">{newsDate-1}</div></li>            
                                            <li class="odd"><a href="{url}/index.php?url=news&id={newsID-2}">{newsTitle-2} &raquo;</a><div class="newsitem-date">{newsDate-2}</div></li>            
                                            <li class="last"><a href="/news">More news &raquo;</a></li>            
                                        </ul>
                                    </div>
                                    <script type="text/javascript">
                                        document.observe("dom:loaded", function() { NewsPromo.init(); });
                                    </script>
                                </div>
                            </div>
    			
    
    				<div id="column2" class="column1">
                            <div class="habblet-container ">
                                <div class="cbb clearfix blue ">
                                    <h2 class="title">Statistics</h2>
                                    <div style="padding:0px">
         <IMG SRC="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSjI0TOL0RhyA0MpAb-6VFAPdBhuxgJTdGrMMff-QDkWVppntzGmw" ALT="picture of a pumpkin" ALIGN=LEFT>
         <br>Check out the updates on counts and users with actiivites going on in the hotel!<br>
    <br><hr noshade size="1" width="80%"><center><strong>Number of rooms:</strong>
    <p><?php
    
    $link = mysql_connect("localhost", "root", "naruto123");
    mysql_select_db("rp", $link);
    
    $result = mysql_query("SELECT * FROM rooms", $link);
    $num_rows = mysql_num_rows($result);
    
    echo "$num_rows \n";
    
    ?>
    <br><hr noshade size="1" width="80%"<br>
    <strong>Number of coorporations:</strong><br>
    0<br><hr noshade size=1 width="80%">
    <strong>Number of police officers:</strong><br>
    0<br><hr noshade size=1 width="80%">
                                    </div>
                                </div>
                            </div>
                        </div>
    				<script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
    				
                <script type="text/javascript">
                    document.observe('dom:loaded', function() {
                        CurrentRoomEvents.init();
                    });
                </script>
            </div>
    
            <script type="text/javascript">if (!$(document.body).hasClassName('process-template')) { Rounder.init(); }</script>
            <script type="text/javascript">
                HabboView.run();
            </script>
    		
    		
    		
            <!--[if lt IE 7]>
                <script type="text/javascript">
                    Pngfix.doPngImageFix();
                </script>
            <![endif]-->
            
    
    		    <!-- Includes the footer -->
    			<?php include('footer.php'); ?>
    			<!-- if banned sends to URL = banned/ipbanned -->
    			<?php include('checktheban.php'); ?>
            </div>
        
        </body>
    </html>
    Or explain how </div>'s work . Thanks :)


  2. #2
    Valued Member moere is offline
    MemberRank
    Apr 2012 Join Date
    121Posts

    Re: Help with </div>

    Quote Originally Posted by Vaulient View Post
    ...
    Well that's a bit messy. You could only define the container as inline block or play with floats. Do you have a link to the page where I can see it directly (I don't have the whole style sheet available from you which makes it a bit hard?

    --- UPDATE ---

    The problem you have here is that you put everything into the radio div.

    1. Add a float to this part of code
    Code:
    <div id="content" style="position: relative; float:left;" class="clearfix">
    2. Add a float to this part of code
    Code:
    <div class="habblet-container " style="width:460px; float:right;">
    Then you have at least two colums and can continue to extract the divs that have to be on the left side.

    Try to use for a next time a more structured code:
    PHP Code:
    <?PHP all php includes and queries ?>
    <head> all css and js includes (and js codes specifically for the current file)</head>
    <body>
    <div id="header"> Header content including navigation </div>
    <div id="content">
    <div id="sitewidth and other shizzle that is in general for all divs in it">
    <div id="right"></div>
    </div id="left"></div>
    </div>
    </div>
    </body>
    Last edited by moere; 26-03-14 at 12:19 PM.

  3. #3
    Loyalty Vaulient is offline
    MemberRank
    May 2012 Join Date
    MalaysiaLocation
    1,796Posts

    Re: Help with </div>

    http://prntscr.com/34afoh problem solved , close thread please x]



Advertisement