Reputation: 1261
I have two divs with col-xs-12 col-md-9
and col-xs-12 col-md-3
. They appear as expected
on a normal monitor:
on a phone screen:
And here is my issue. I have to adapt the layout to a special screen of 1300x1900 px. Yes, 1300 px width and 1900 px height. Right now it appears like this:
In this case I need something similar to the phone screen layout. Does Bootstrap 3 has something to handle this cases or should I do it manually?
Edit: adding custom screen widths to existing Bootsrap 3 grid doesn't really help. The issue is with screen ratio, not just the absolute screen size.
Upvotes: 1
Views: 795
Reputation: 3950
here is the code for it:
<<!DOCTYPE html>
<!--[if lt IE 7]> <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]> <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]> <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!-->
<html class="no-js">
<!--<![endif]-->
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title></title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<!-- jQuery library -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<!-- Latest compiled JavaScript -->
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css"></script>
</head>
<body>
<!--[if lt IE 7]>
<p class="browsehappy">You are using an <strong>outdated</strong> browser. Please <a href="#">upgrade your browser</a> to improve your experience.</p>
<![endif]-->
<div class="container-fluid">
<div class="container-fluid">
<div class="row">
<div class="col-xs-12 col-sm-9 col-md-9 col-lg-9 col-xl-12" style="background-color: red">
abc</div>
<div class="col-xs-12 col-sm-3 col-md-3 col-lg-3 col-xl-12" style="background-color: blue">
def</div>
</div>
</div>
</div>
<script src="" async defer></script>
</body>
</html>
check out thr fiddle :https://jsfiddle.net/8sydhg9y/1/
Upvotes: 1