How can I keep these two images directly opposite one another until the browser is too small to accommodate them?

How can I get these two images in Bootstrap to not start stacking on top of one another until the browser size makes it necessary?

Here's a screenshot:

screenshot of webpage header
Notice how the image on the right is sliding down? The width of these two images is such where they should be directly opposite one another and I don't understand why they are not.

What do I have to change to ensure these images remain parallel to one another right up until the point where they are butting up against one another? At that point, I would want them to stack directly on top of one another and I've got that covered with the "col-xs-12" dynamic. But what am I missing or what can I include to make sure the two images remain directly opposite one another until that point?

Here's my code:

<div class="container-fluid" style="overflow:hidden;">
			<div class="row-fluid">
				<div class="col-md-6 col-sm-6 col-xs-12" id="header_wwol" style="margin-top:20px;">
					<img src="images/wwol_logo_xs_transparent_09-16-2014.fw.png" class="image-responsive pull-left">
				</div>
				<div class="col-md-6 col-sm-6 col-xs-12" id="header_aha">
					<img class="img-responsive pull-right" alt="Applied Health Analytics" style="margin-top:30px;" src="images/AHALogo300x39.fw.png">
				</div>
			</div>
			<div class="row">
				<div class="col-xs-12">&nbsp;<br></div>
			</div>
			<div class="row-fluid">
				<div class="col-xs-12" class ="header_div" style="background-image:url('images/header_divider.jpg'); background-repeat:x-repeat; width:105%; margin-left:-25px; height:41px;">&nbsp;</div>
			</div>
			<div class="row">
				<div class="col-xs-12">&nbsp;<br></div>
			</div>
		</div>

Open in new window

brucegustPHP DeveloperAsked:
Who is Participating?
 
Shaun VermaakConnect With a Mentor Technical Specialist/DeveloperCommented:
If I understand you correctly col-xs-12 should be col-xs-6 and img-responsive class should be added to images
0
 
brucegustPHP DeveloperAuthor Commented:
Shaun, you put the wheels in motion that got it done!

Thanks!

Here's what we landed:

Here's my CSS:

@media (max-width: 766px) {
			
			.aha_logo {
				float: none !important;
				margin:auto;
				display:block;
				margin-top:15px;
			}
			
			.wwol_logo {
				margin:auto;
				display:block;
			}
			
			.content {
				max-width:625px; 
				border:1px solid #4f77b3;
				-moz-border-radius: 14px 14px 14px 14px; 
				border-radius: 14px 14px 14px 14px; 
				box-shadow:7px 7px 10px #4f77b3		margin:auto;
				}
				
		}
			
			
		/* Landscape phones and portrait tablets */
		@media (min-width: 767px) {

			#header_wwol {
			margin-top:20px;
			text-align:center;			
			}
			
			.aha_logo {
				margin-top:20px;
			}
		
		}

Open in new window


...and here's the HTML:

<div class="row-fluid">
				<div class="col-md-6 col-sm-6 col-xs-12" id="header_wwol" style="margin-top:5px;">
					<img src="images/wwol_logo_xs_transparent_09-16-2014.fw.png" class="img-responsive wwol_logo">
				</div>
				<div class="col-md-6 col-sm-6 col-xs-12" id="header_aha">
					<img class="img-responsive pull-right aha_logo" alt="Applied Health Analytics" src="images/AHALogo300x39.fw.png">
				</div>
			</div>

Open in new window


Your suggestion of changing col-xs-12 to col-xs-6 got me moving in the right direction, as far as realizing that I had to have both dynamics in there and then add the media query.

Rock on!
1
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.