?
Solved

Bootstrap - CSS

Posted on 2016-08-25
1
Medium Priority
?
93 Views
Last Modified: 2016-08-27
Please look at http://rkassoc.org/Houston/.

Note how the tan background extends to the right. Note in the code (HTML), things are centered. I do not want the excess background on the right.

How do I get rid of it?

<!DOCTYPE html>
<html>

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
    <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">

    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>

    <script src="//code.jquery.com/jquery-1.10.2.js"></script>
    <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script>
    <link rel="stylesheet" href="/resources/demos/style.css">

    <title>City of Houston Backflow Assembly & Test Report Form</title>
    <style>
        .nopadding {
            padding: 0 !important;
            margin: 0 !important;
        }
        
        .wrapper {
            max-width: 767px;
            min-width: 480px;
            margin: 0 auto;
        }
    </style>
	<script>
	function chk_vals() {
		if (document.st.uid.value == "" || document.st.pwd.value == "") {
			alert("Please enter Email & Password");
			return false;
		}
		return true;
	}
	</script>
</head>	
<body>
<div class="wrapper">
<form method="POST" name="st" action="chk_login.php" onSubmit="return chk_vals();">
<div class="container-fluid" style="background-color: #F3D9AF;">
<div class="row" style="background-color: #F3D9AF;">
    <div class="col-xs-8 text-center"><img src="images/bfp_logo_sm.jpg"></div>
</div>
<div class="row" style="background-color: #F3D9AF;">
       <div class="col-xs-8 text-center" style="font-size:18px;"><b>Backflow Assembly & Test Report Form</b></div>
 </div>
 	
	<div class="row" style="background-color: #F3D9AF;">
         <div class="col-xs-8 text-center"><b>User Login</b></div>
    </div>
				<div class="row">
                    <div class="col-xs-8">User ID: (Email)</div>
                </div>
				<div class="row">
                    <div class="col-xs-8"><input type="text" name="uid" style="width:200px;"></div>
                </div>
				<div class="row">
                    <div class="col-xs-8">Password:</div>
                </div>
				<div class="row">
                    <div class="col-xs-8"><input type="password" name="pwd" style="width:200px;"></div>
                </div>
	<div class="row" style="background-color: #F3D9AF;">
        <div class="col-xs-8 text-center" style="padding-top:10px;">
            <input type="submit" value="Login">
        </div>
    </div>
            </div>
        </form>
    </div>
</body>

</html>	

Open in new window

0
Comment
Question by:Richard Korts
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 58

Accepted Solution

by:
Julian Hansen earned 2000 total points
ID: 41770941
Your content is all inside the following elements
<div class="col-xs-8">

Open in new window

This is restricting your content to the left 75% of the parent container.

You need to make that col-xs-12 to extend to the full width of the parent. If that is too wide then you need to put the parent into a container of its own - something like

<div class="row">
   <div class="col-xs-8 col-xs-offset-2">
         <!-- Login box markup goes here -->
   </div>
</div>

Open in new window


The col-xs-offset class basically pushes the container left the specified number of columns. Because the content area is 8 columns wide - leaves 4 columns which we divide by 2 to get the offset value.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction If you're like most people, you have occasionally made a typographical error when you're entering information into an online form.  And to your consternation, the browser remembers the error, and offers to autocomplete your future entr…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
Suggested Courses
Course of the Month9 days, 21 hours left to enroll

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question