Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8707633
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T03:55:09+00:00 2026-06-13T03:55:09+00:00

Need help. I cannot figure out why I cannot place div side by side

  • 0

Need help.
I cannot figure out why I cannot place div side by side in the child .aspx of master page.

The code works if I hardcode the style like this

<div id="pagemiddleleft" style="float:left;"> 

But when I move the style into the CSS file, the div’s refuse to sit side by side.

Below is the child code

<%@ Page Title="Home Page" Language="VB" MasterPageFile="~/Site.Master"
AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>

<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
<div id="pagetop">
</div>
<div id="pagemiddle">
        <div id="pagemiddleleft">111111
        </div>
        <div id="pagemiddlecenter">111111
        </div>
        <div id="pagemiddleright">111111
        </div>
        <div style="clear: both"></div>
</div>
<div id="pagebottom">
</div>
</asp:Content>

Below is an extraction of the Master Page

 <div class="page">
    <div class="main">
        <asp:ContentPlaceHolder ID="MainContent" runat="server"/>
    </div>
    <div class="clear">
    </div>
 </div>

Below is the CSS portion for the child aspx page

#pagemiddleleft {
float: left; background-color: #FFFF00;}

#pagemiddlecenter {
float: left; background-color: #00FFFF;}

#pagemiddleright {
float: right; background-color: #FF00FF;}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T03:55:10+00:00Added an answer on June 13, 2026 at 3:55 am

    Try this master page layout

    Master Page

        <%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>
    
        <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
        <html xmlns="http://www.w3.org/1999/xhtml">
        <head runat="server">
            <title></title>
            <asp:ContentPlaceHolder ID="head" runat="server">
    
            </asp:ContentPlaceHolder>
            <style type="text/css">
            div.page
            {
                float: left;
                width: 100%;
                background:#ffc;
            }
            div#main
            {
                float: left;
                clear: both;
                width: 100%;
                position: relative;
            }
            div#page-left
            {
                float: left;
                width: 20%;
                background:orange;
            }
            div#page-right
            {
                float: right;
                width: 20%;
                background:green;
            }
            div#page-middle
            {
                float: left;
                margin: 0 auto;
                width: 60%;
                background:blue;
            }
        </style>
        </head>
        <body>
            <div class="page">
                <div id="main">
                    <form id="form1" runat="server">
                    <div id="page-left">
                       <asp:ContentPlaceHolder ID="leftContent" runat="server"></asp:ContentPlaceHolder>
                    </div>
                    <div id="page-middle">
                        <asp:ContentPlaceHolder ID="middleContent" runat="server"></asp:ContentPlaceHolder>
                    </div>
                    <div id="page-right">
                     <asp:ContentPlaceHolder ID="rightContent" runat="server"></asp:ContentPlaceHolder>
                    </div>
                    </form>
                </div>
            </div>
        </body>
        </html>
    

    Content Page

        <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" MasterPageFile="~/MasterPage.master"
            Inherits="_Default" %>
    
        <asp:Content ContentPlaceHolderID="leftContent" runat="server" ID="PageLeft">
            Page Left Contentt</asp:Content>
        <asp:Content ContentPlaceHolderID="middleContent" runat="server" ID="PageMiddle">
            Page Middle Content</asp:Content>
        <asp:Content ContentPlaceHolderID="rightContent" runat="server" ID="PageRight">
            Page Right Content</asp:Content>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Need help with an error message that I just can't figure out. I am
I got some help with this earlier today but I cannot figure out the
Can some please help? I cannot figure out why I am getting this error
I need help figuring out these php print (echo) statements and where to place
I need help with one ajax function This is raw page setup. Page will
I cannot figure out how to put a recursive inside an XSL for a
I am using Grails 1.3.7 and cannot figure out how to get version 4.0
I cannot figure out why my query slows down. What it boils down to
I am very new to apache server so I cannot figure out how to
I have this regex in a query in postgres and I cannot figure out

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.