stretch the boxes to have an organized menu with CSS - html

I have a menu and I want to stretch the boxes in this menu to have an organized one
I tried like this,this is my code:
<div class="col-sm-1">
<ul class="nav-gproS">
<li>
<a style="margin-top: 10px" class="btn btn-action pull-right"
href="" ng-click="go1()">F.Suiveuse</a>
</li>
<li class="active">
<a style="margin-top: 10px" class="btn btn-action pull-right"
href="" ng-click="go2()">Suivi/Poste</a>
</li>
<li>
<a style="margin-top: 10px" class="btn btn-action pull-right"
href="" ng-click="go3()">Personnel</a>
</li>
<li>
<a style="margin-top: 10px" class="btn btn-action pull-right"
href="" ng-click="go4()">Avct OF</a>
</li>
</ul>
</div>
and this is the CSS code:
.nav-gproS {
list-style-type: none;
}
.btn-action {
background: #1f8597;
color: #fff;
border-radius: 0px;
font-weight: 600;
}
.btn {
font-family: 'Open Sans', 'Segoe UI', 'Droid Sans', Tahoma, Arial, sans-serif;
border-width: 0px;
-webkit-box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
}
.pull-right {
float: right !important;
}
what I get is a non organized menu,so how can modify my CSS
thanks for help

I'm suggesting adding to your existing <a> tags class .btn-block. Also remove .pull-right and set text-align: right to your .btn-action declaration or add class .text-right.
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" />
<style>
.nav-gproS {
list-style-type: none;
}
.btn-action {
background: #1f8597;
color: #fff;
border-radius: 0px;
text-align: right;
/* text right added here*/
font-weight: 600;
}
.btn {
font-family: 'Open Sans', 'Segoe UI', 'Droid Sans', Tahoma, Arial, sans-serif;
border-width: 0px;
-webkit-box-shadow: inset 0 0px 0px 0px rgba(0, 0, 0, 0.07);
box-shadow: inset 0 0px 0px 0px rgba(0, 0, 0, 0.07);
}
.pull-right {
float: right !important;
}
</style>
<div class="col-sm-3">
<ul class="nav-gproS">
<li>
<a style="margin-top: 10px" class="btn btn-action btn-block" href="" ng-click="go1()">F.Suiveuse</a>
</li>
<li class="active">
<a style="margin-top: 10px" class="btn btn-action btn-block" href="" ng-click="go2()">Suivi/Poste</a>
</li>
<li>
<a style="margin-top: 10px" class="btn btn-action btn-block" href="" ng-click="go3()">Personnel</a>
</li>
<li>
<a style="margin-top: 10px" class="btn btn-action btn-block" href="" ng-click="go4()">Avct OF</a>
</li>
</ul>
</div>

.nav-gproS {
list-style-type: none;
}
.nav-gproS a { /*Set a width on your links, so they get the same width*/
width: 150px;
text-align: right;
}
.btn-action {
background: #1f8597;
color: #fff;
border-radius: 0px;
font-weight: 600;
}
.btn {
font-family: 'Open Sans', 'Segoe UI', 'Droid Sans', Tahoma, Arial, sans-serif;
border-width: 0px;
-webkit-box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
}
.pull-right {
float: right !important;
}

Since you're using Bootstrap I have another suggestion. Remove the list entirely and add .btn-block to your anchors since Bootstrap can handle anchors as full-width, block-style buttons already.
Check This Out
<div class="col-sm-1">
<a style="margin-top: 10px" class="btn btn-block btn-action" href="" ng-click="go1()">F.Suiveuse</a>
<a style="margin-top: 10px" class="btn btn-block btn-action" href="" ng-click="go2()">Suivi/Poste</a>
<a style="margin-top: 10px" class="btn btn-block btn-action" href="" ng-click="go3()">Personnel</a>
<a style="margin-top: 10px" class="btn btn-block btn-action" href="" ng-click="go4()">Avct OF</a>
</div>
.btn-action {
background: #1f8597;
color: #fff;
border-radius: 0px;
font-weight: 600;
}
.btn {
font-family: 'Open Sans', 'Segoe UI', 'Droid Sans', Tahoma, Arial, sans-serif;
border-width: 0px;
-webkit-box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
box-shadow: inset 0 0px 0px 0px rgba(0,0,0,0.07);
}

Related

float lef outlook signature solution

im trying to make an outlook signature with html.
I dont know how can i do a signature email with 3 rows
what i want
what i get
There is my code:
<section id="2" style="float: left; position:relative; margin-left: 230px; width: 250px;">
<div id="user" style="margin-top: 10px;">
<h1 style="margin: 0px 0px 5px 0px !important; font-size: 20px; color: #414042; font-weight:bolder; font-family: Arial, Helvetica, sans-serif;">Adriano Medeiros</h1>
<h2 style="margin: 5px 0px 0px 0px !important;font-size: 16px; color: #414042; font-family: Arial, Helvetica, sans-serif; font-weight: normal;">MARKETING DIRECTOR</h2>
<h3 style="margin: 10px 0px 0px 0px !important; font-size: 14px; color: #414042; font-family: Arial, Helvetica, sans-serif; font-weight: normal;">Dpt. Marketing e Comunicação</h3>
</div>
<div id="email" style="margin-top: 10px;">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAB8AAAAUCAYAAAB1aeb6AAAACXBIWXMAABYlAAAWJQFJUiTwAAABiUlEQVRIieWVvXXCMBSFP3HoYYQ0qgMThEwQGtWYDcwGMAFkAkyLCjwC2cBpUUM2MBO8FJJPHBMn5rfJLe139Pndd5+sRARnVQRE3Ec5EGkjuRIRAJxVCTC6MfgDGGojGYDarUmAWBvJgwPLG4HfgUHgDIGHFr7brbOqq40kwDNwuDJ4VQJHwAbotsLLR2DvrOppI1tggLfoGpppI1EAJ5ScbZWKOngHipn08FZdorE2MnVWdZ1VKZVMtSrFHWDjrIq0kRzvwOoM6AHoayOJs6oLbIGXalEVXmjprEq0kVwbiYDXE8BFsDJnVQ/Y48d6pDo4wMhZlYYgxsC4AfitBI7wHXfqin+Dg7eqvAl96jdhpY0UiY7xwaoFN4HD903I8DmoBnESxlNcVvMG59JuUsTXJsQhRAMgDu8ybSQNwUqBp4ZnonZrpGlx0EQbWZQfhGAl1ASrRrOmnZc1D50XH9ADpvwx3590Dhx8EI/29lQ1CdzN9L/hl/48zlXWxl8aC+DhjuCFNpJ+Agxhobt2v5EjAAAAAElFTkSuQmCC" alt="email" style="width: 20px; position: absolute; margin-top: 15px;">
<p style="margin-top:15px; float: left; margin-left: 40px; font-size: 14px; font-family: Arial, Helvetica, sans-serif;color: #414042; font-weight: bold;">Adriano.medeiros#homa.pt</p>
</div>
</section>
<section id="3" style="float: left; width: 273px; ">
<div class="line" style=" margin-top:10px;border-left:2px solid #D9AB28; height: 130px;position: absolute;"></div>
<div class="contacts" style="margin-left: 30px;">
<div class="telefone">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAAaCAYAAABCfffNAAAACXBIWXMAABYlAAAWJQFJUiTwAAABU0lEQVRIibXVwVECMRTG8X8Y79CBcMgZrUBL4JKzawd04NoBVuByNRfogBLgai5rB1LB80AW1zWQ4MbvxMyb2d+Q916iRIT/zlXzw1lVAHNgCuy0kZtcyKAFvHoAYOqsKnMh6v2NBghloo3UfZEBsDhTr/oCDTI8U79zVs1zILHMciC7vh9JQc71BDL0RYkIzqoauA7Ub7WRbV+k6Unv5kYRbWQFrAP1jbOq9+a3p6sA9p36MAd0RLSRT8Lj2hv6sSfayAZ4zA39WkZtpAKWOSF16j1xVlXAQ6C0B+7bo+2sGgNjoA5dqCeRVMhZNQK2fO/ZM7DwPY4jCdCMw40x7dQ+gML3OI5EoFhegDIJ8VAJPP0BWqdc9QBoIyWH8e4ubCx1MuKhCrjnsudhm3xc3SQe31IbKS76J+3445sQXtwjAInTFYtfxhmHoxwBK23k+Bh+AZQCix9ZmcqxAAAAAElFTkSuQmCC" alt="phone number"style="float:left; margin-right:20px; width: 20px;">
<h2 style="padding-top: 7px; font-size: 14px; font-family: Arial, Helvetica, sans-serif;color: #414042; font-weight: bold;">960000000000 | Ext. 22044</h2>
</div>
<div class="smartphone number">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAjCAYAAAB7NEEmAAAACXBIWXMAABYlAAAWJQFJUiTwAAAA90lEQVRIie2WPW7DMAxGHw2PGXKDyEA8NzdpFs9tTlZ3jZbmBj2Cu0ZDfYM2J2CHUqmHAjEkLwLCRZTE70H/oqgqS1u1OLEoaB2d4MUBLoM1tp2OAKKqBC/PwEsGMNqh7bSX8xEHfFrjCRgSYDvg0fym5m/Kp7bTfeoQg5c3A7vpRqWMcGpXfTlHqizo1vxdJivqtxWwsso6Exr1q7LWtBxovF7vmayoH8qa/h16h8I+eEl6qUx3/TTrSd8DMAQvYwLXAZv/oFjHhkybu6YfQGPlYtDe8qR+TrCcj6yBrxmxr8DTjLimajv9Bg7A5UbwLeCF3wRt/AFdyDg/DvcalwAAAABJRU5ErkJggg==" alt="smartphone number" style="float:left; margin-right: 20px; margin-top: 5px; width: 20px;">
<h2 style="padding-top:15px; font-size: 14px; font-family: Arial, Helvetica, sans-serif;color: #414042; font-weight: bold;">2222222222</h2>
</div>
Outlook uses Word for rendering message bodies. In Word, two HTML elements that support a subset of the cascading style sheets properties are called out: DIV and P. Read more about supported and unsupported HTML elements, attributes, and cascading style sheets properties in the Word HTML and CSS Rendering Capabilities in Outlook article.
Note, Outlook for desktop doesn't support base64 images. You'd need to attach an image and then use the cid: attribute to refer to the attached image.

CSS underline with same with as above element

I am trying to create the following look:
As you can see on this picture even if there is some padding on the "sub" menu item the border still works.
So here is what I've attempted:
.menu-ul {
list-style-type: none;
}
.menu-li {
padding: 10px 0;
border-bottom: 1px solid rgba(50, 50, 50, 0.3);
width: 100%;
}
a {
font-family: Titillium Web;
font-style: normal;
font-weight: 600;
font-size: 16px;
line-height: 24px;
letter-spacing: 0.02em;
color: #323232;
text-decoration: none;
}
a:hover {
color: #DB091C;
}
.sub-menu-ul {
padding: 0px;
list-style-type: none;
border-top: 1px solid rgba(50, 50, 50, 0.3);
}
.sub-menu-li {
padding: 10px;
width: calc(100% - 20px);
border-top: 1px solid rgba(50, 50, 50, 0.3);
}
hr.solid {
border-top: 3px solid #bbb;
}
<link href="https://pro.fontawesome.com/releases/v5.14.0/css/all.css" rel="stylesheet"/>
<nav style="width: 300px">
<ul class="menu-ul">
<li class="menu-li">
<a href="" >Title </a>
<span style="float: right"><i class="fa fa-angle-down"></i></span>
<div style="display: block">
<ul class="sub-menu-ul">
<li class="sub-menu-li"> <a href="#">
Sub menu item2
</a>
<span style="float: right"><i class="fa fa-angle-right"></i></span>
</li>
</li>
<li class="sub-menu-li"> <a href="#">
Sub menu item2
</a>
</li>
</ul>
</div>
</li>
<li class="menu-li"><a href="" >Title 2</a>
</li>
<li class="menu-li"><a href="" >Title 2</a> </li>
</ul>
</nav>
But I can't seem to get the border right.
Try this, I have changed the padding for menu-li and width of sub-menu-li
.menu-li {
padding: 10px 0;
border-bottom: 1px solid rgba(50, 50, 50, 0.3);
width: 100%;
}
.sub-menu-li {
padding: 10px;
padding-right: 0;
width: calc(100% - 10px);
border-top: 1px solid rgba(50, 50, 50, 0.3);
}

how to clear black dash in html button?

I don't know how to describe my problem but look at my output you'll get an idea. I
googled about my problem but i couldn't found the solution.
.btn1 {
font-family: 'Times New Roman', Times, serif;
margin-right: 0px;
width: 100px;
height: 30px;
font-size: 17px;
font-weight: 200;
background-color: #f7e7e7;
color: rgb(49, 126, 126);
border-radius: 5px;
border: 1px solid rgb(186, 230, 173);
box-shadow: 3px 3px rgb(98, 151, 98);
}
<div>
<a href="#">
<button class="btn1">Home</button>
</a>
<a href="product.html">
<button class="btn2">Products</button>
</a>
<a href="#">
<button class="btn3">Buy Now</button>
</a>
<a href="findus.html">
<button class="btn4">Find us</button>
</a>
</div>
Every button have same code in CSS.
Can you please tell, what am i doing wrong?
Thank you.
You have unnecessarily wrapped each of your <button>s in an <a> tag and this is the browser's default underline style of the <a> tag that you can see.
Note: Some of the other answers suggest simply hiding the underline, but wrapping a <button> in an <a> is considered to be an anti-pattern that should be avoided.
Links
.btn1 {
font-family: 'Times New Roman', Times, serif;
margin-right: 0px;
width: 100px;
height: 30px;
font-size: 17px;
font-weight: 200;
background-color: #f7e7e7;
color: rgb(49, 126, 126);
border-radius: 5px;
border: 1px solid rgb(186, 230, 173);
box-shadow: 3px 3px rgb(98, 151, 98);
text-decoration: none;
}
<div>
<a class="btn1" href="#">Home</a>
<a class="btn1" href="product.html">Products</a>
<a class="btn1" href="#">Buy Now</a>
<a class="btn1" href="findus.html">Find us</a>
</div>
Buttons
.btn1 {
font-family: 'Times New Roman', Times, serif;
margin-right: 0px;
width: 100px;
height: 30px;
font-size: 17px;
font-weight: 200;
background-color: #f7e7e7;
color: rgb(49, 126, 126);
border-radius: 5px;
border: 1px solid rgb(186, 230, 173);
box-shadow: 3px 3px rgb(98, 151, 98);
}
<div>
<button class="btn1">Home</button>
<button class="btn2">Products</button>
<button class="btn3">Buy Now</button>
<button class="btn4">Find us</button>
</div>
You can read about links vs buttons, and why you might choose one over the other here.
The dashes you are seeing are actually the default underline that accompanies anchor elements. All you need to add is:
a {
text-decoration: none;
}
That being said, nesting button elements inside of anchor elements is invalid HTML and should be avoided.
Replace a with button or use css rule text-decoration: none
.btn {
font-family: "Times New Roman", Times, serif;
margin: 10px;
padding:10px;
width: 100px;
height: 30px;
font-size: 17px;
font-weight: 200;
background-color: #f7e7e7;
color: rgb(49, 126, 126);
border-radius: 5px;
border: 1px solid rgb(186, 230, 173);
box-shadow: 3px 3px rgb(98, 151, 98);
}
a
{
text-decoration:none;
color: black;
}
<div>
<a href="#" class="btn">
Home
</a>
<a href="product.html" class="btn">
Product
</a>
<a href="#" class="btn">
buy now
</a>
<a href="findus.html" class="btn">
find us
</a>
</div>

Dropdown Menu Automatically Open in IE

I'm making a landing page for a client with a dropdown menu. I'm using bootstrap. I've been having an issue where the dropdown options are already expanded on page load, but only for IE. They also do not have any of the normal formattings for an 'expanded' dropdown (background color should be white, it's not, etc.) Instead, all the li are translucent gray. The options are hoverable and selectable, but the dropdown menu will not close (the caret is essentially unresponsive).
This problem has happened before, on other sites, for this same client. The weirdest thing is, in the past, I have been able to get it to work by merely uploading the folder again to the client's servers. Same code, not working once, then uploaded again and then working. For the life of me, I can't figure out why this is happening
.hero .hero-selection select {
width: 250px;
border: none;
font-size: 14px;
font-family: Proxima Nova Thin;
-moz-box-shadow: 0 0 0 35px rgba(255, 255, 255, .2);
-webkit-box-shadow: 0 0 0 35px rgba(255, 255, 255, .2);
box-shadow: 0 0 0 35px rgba(255, 255, 255, .2);
background-color: #FFF;
color: #999;
border-radius: 0!important;
-webkit-appearance: none;
-moz-appearance: none;
-ms-appearance: none;
appearance: none;
padding: 15px 10px 10px;
}
.hero .hero-form-container .dropdown-menu {
position: absolute;
top: 100%;
left: 0;
z-index: 1000;
display: none;
float: left;
min-width: 160px;
font-size: 14px;
text-align: left;
list-style: none;
background-color: #fff;
background-clip: padding-box;
border: 1px solid rgba(0, 0, 0, .15);
border-radius: 4px;
box-shadow: 0 6px 12px rgba(0, 0, 0, .175);
margin: 2px 0 0;
padding: 5px 0;
}
.hero .hero-form-container .dropdown-menu>li>a {
display: block;
clear: both;
font-weight: 400;
line-height: 1.42857143;
color: #333;
white-space: nowrap;
padding: 3px 20px;
}
.hero .hero-form-container ul {
width: 250px;
top: 91px;
border-radius: 0;
border: none;
background-color: #FFF;
color: #999;
padding: 0;
}
.hero .hero-form-container ul li a:hover {
background-color: #99d425;
font-family: Proxima Nova Thin;
font-size: 14px;
color: #999;
padding: 5px 5px 5px 15px;
}
.hero .hero-form-container ul li a {
font-family: 'Proxima Nova Thin';
font-size: 14px;
color: #999;
text-decoration: none;
padding: 5px 5px 5px 15px;
}
<div class="row">
<div class="col-sm-6 pull-left"><img id="nats-logo" style="" src="img/nats-logo-red.png" alt=""></div>
<div class="col-sm-6">
<div class="hero">
<div class="hero-form">
<div class="dropdown hero-selection">
<h5>Select your utility below:</h5>
<h2 style="margin-top: 20px">My Electricity Utility is:</h2>
<div class="btn-group">
<button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu2" data-toggle="dropdown" aria-expanded="true"> Select One<span class="caret"></span> </button>
<ul class="dropdown-menu" role="menu">
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="notlisted" class="is-active">[not listed]</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="EBG">BGE</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="CNM">Delmarva Power (MD)</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="PED">Pepco (DC)</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="PEM">Pepco (MD)</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="APM">Potomac Edison</a></li>
<li role="presentation"><a role="menuitem" tabindex="-1" href="#" value="SME">SMECO</a></li>
</ul>
</div>
<form action="https://one.wglenergy.com/portal/rc_engine_by_ldc.php" id="form1">
<input type="hidden" name="super_rc" value="NATS">
<input type="hidden" name="cust_type" value="RES">
<input type="hidden" name="ldc_g" id="ldc_g">
<input type="hidden" name="ldc_e" id="ldc_e">
<input type="submit" id="go-button" value="See Your Pricing">
</form>
</div>
</div>
</div>
</div>
</div>

My content goes out of the div

I got a problem with the div. It must look like this: http://cl.ly/2r0S043m301p410T2e3z but instead it looks like this: http://cl.ly/3h1t0f471W0V1U3j2S0y it is really annoying.
Here is the HTML:
<html xmlns="http://www.w3.org/1999/html">
<head>
<link href="<?php echo base_url('css/style.css');?>" rel="stylesheet" type="text/css" />
<title>Admin :: Home</title>
</head>
<body>
<div id="wrapper">
<div class="admin-form">
<div class="header">
<h1>Admin Home</h1>
</div>
<div class="content dashboard">
<ul>
<li><img src='<?php echo base_url('images/icons/scubadiving.png');?>'/><p>Duiklocaties</p></span></li>
<li><img src='<?php echo base_url('images/icons/users.png');?>'/><p>Gebruikers</p></span></li>
</ul>
</div>
</div>
</div>
</body>
</html>
and here is the CSS for that content box:
.admin-form .content .input {
width: 188px;
height: 100%;
padding: 15px 25px;
margin-left: 100px;
font-family: "HelveticaNeue-Light", "Helvetica Neue Light", "Helvetica Neue", Helvetica, Arial, "Lucida Grande", sans-serif;
font-weight: 400;
font-size: 14px;
color: #9d9e9e;
text-shadow: 1px 1px 0 rgba(255,255,255,1.0);
background: #fff;
border: 1px solid #fff;
border-radius: 5px;
box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
-moz-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
-webkit-box-shadow: inset 0 1px 3px rgba(0,0,0,0.50);
}
I'm assuming you've floated the li or a. In which case, you should add a clearfix class to the parent container
<div class="content dashboard clearfix">
Here is the clearfix class code:
.clearfix:before,.clearfix:after{
content:'\0020';
display:block;
overflow:hidden;
visibility:hidden;
width:0;
height:0
}
.clearfix:after{clear:both}
.clearfix{zoom:1}
You don't have a tags closed. Is that typo?
<a href='<?php echo base_url('admin/DiveLocations');?>'<span...
should be
<a href='<?php echo base_url('admin/DiveLocations');?>' ><span..