Jump to content

maintain the button and textbox in the orignial location


angel777

Recommended Posts

hi i wonder how do i solve my css problem.

when i try to minimize my internet browser' width to be smaller, the textbox and the button will be running out of the location. how do i maintain the button and textbox in the orignial location ?

 

my code is as below; but i wonder why when i drag the browser, those textbox and button are moving..

 

echo "<span class=\"section\" id=\"top_right2\">";                 
          echo "<button class='query_button' name='query' id='query' onclick='autoUpdate();'>Query</button>";   
           echo "<button class='top_button' name='edit_db' id='edit_db' style='border-style: outset' onclick='CrossClassEvent(CLASS_ID_HEADER,HEADER_EVENT_ID_EDIT_DB_CLICKED);'>Edit Database</button>";       
          
echo "</span>";

 

 

.section#top_right2 {
    position: relative;
    padding-top: 0em;
    padding-bottom: 0em;
    left: 2%;
    top:  -70%;
    _top: -40%
}

You have "left: 2%" in your CSS. This means that the distance from the left of the screen is 2 percent of the width of the screen. If you make your browser smaller, then 2% becomes a smaller amount, so it shifts left.

 

Make the left value a static amount (px), and it should solve your problem.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.