Using a Sprite Image for Search Box Input Button - html

EDIT: You can see the search box live here.
Before I explain, let me show you the code I am using:
HTML
<div class="SiteSearch">
<form action="/search" id="searchform" method="get">
<input x-webkit-speech="" autocomplete="off" type="text" id="gText" name="q" id="q" onblur="if (this.value == '') {this.value = 'Search';}" onfocus="if (this.value == 'Search') {this.value = '';}" value ='' "search" placeholder="Search.."/>
<input type="submit" id="gBtn"/>
</form>
</div>
CSS
#Head .SiteSearch {
top: 12px;
right: 0;
}
#Head .SiteSearch {
float: right;
position: relative;
}
input#gText {
float: left;
width: 225px;
height: 23px;
line-height: 24px;
text-indent: 5px;
font-family: arial,sans-serif;
font-size: 1em;
color: #333;
background: white;
border: solid 1px #D9D9D9;
border-top: solid 1px silver;
border-right: none;
vertical-align: middle;
-webkit-appearance: none;
-webkit-border-radius: 0px;
}
#searchform #gBtn {
background-image: url('search.png');
width: 31px;
height: 27px;
}
#gBtn {
vertical-align: middle;
cursor: pointer;
width: 40px;
height: 31px;
line-height: 100%;
padding: 0;
font-size: 0;
text-indent: -999px;
color: transparent;
background-position: 0 0;
border: none;
-webkit-appearance: none;
-webkit-border-radius: 0px;
}
input#gBtn:hover {
background-position: 31px 0;
border: none;
}
This is how the search box looks on IE7 vs. IE8/IE9:
vs.
As you can see above, the input button image isn't being shown in IE7. How can I fix this?
Any help is appreciated. Thanks!

I fixed it by modifying the CSS code like so:
#Head .SiteSearch {
top: 12px;
right: 0;
}
#Head .SiteSearch {
float: right;
position: relative;
}
input#gText {
float: left;
width: 225px;
height: 23px;
line-height: 24px;
text-indent: 5px;
font-family: arial,sans-serif;
font-size: 1em;
color: #333;
background: white;
border: solid 1px #D9D9D9;
border-top: solid 1px silver;
border-right: none;
vertical-align: middle;
-webkit-appearance: none;
-webkit-border-radius: 0px;
}
/* REMOVED THIS PIECE
#searchform #gBtn {
background-image: url('search.png');
width: 31px;
height: 27px;
}*/
#gBtn {
vertical-align: middle;
cursor: pointer;
width: 40px;
height: 31px;
line-height: 100%;
padding: 0;
font-size: 0;
text-indent: -999px;
color: transparent;
background-image: url('search.png'); /* ADDED */
background-position: 0 0;
border: none;
-webkit-appearance: none;
-webkit-border-radius: 0px;
}
input#gBtn:hover {
background-image: url('search.png'); /* ADDED - BUT OPTIONAL */
background-position: 31px 0;
border: none;
}

Write background instead of background-image in your #gBtn button. May be that's work

Related

CSS-styling on my form doesn't work on Firefox

I have this login form, which works and looks just fine in Chrome, IE11 and Edge but when try it out on Firefox, it looks completely different;
My labels are not the same width, so I have to re-adjust them. Also, my submit button doesn't seem to take on styles.
How can I make this work with Firefox as well?
My HTML:
<div class="loginheader">تسجيل الدخول</div>
<div class="loginform">
<form action="login.php" method="post" name="myform" id="myform">
<p>
<label for="loginform">اسم المستخدم</label>
<input type="text" name="username" id="login" value="mohammed.nasyia#gmail.com" placeholder="اسم المستخدم" />
</p>
<p>
<label for="loginform">كلمة المرور</label>
<input type="password" name="password" id="password" value="mohammed.nasyia#gmail.com" placeholder="كلمة المرور" />
</p>
<p >
<input type="submit" name="submit" value="تسجيل الدخول" class="button admin-login-button"/>
</p>
</form>
</div>
<div class="loginfooter">
تسجيل الدخول كممتحن
</div>
</div>
CSS:
.login-container {
margin-top: 100px;
margin-bottom: 50px;
margin-left: auto;
margin-right: auto;
width: 600px;
}
.loginform {
direction:RTL;
padding: 55px;
background-color: #fff;
border: 1px solid #eee;
border-bottom: 0px;
border-top: 0px;
}
.loginheader {
text-align: center;
background-color: #f5f5f5;
padding: 15px 0px;
border-radius: 10px 10px 0 0;
font-size: 30px;
}
.loginfooter {
padding: 15px 40px;
background-color: #f5f5f5;
border-radius: 0px 0px 10px 10px;
font-size: 18px;
text-align: center;
}
.loginheader, .loginfooter {
background-color: #f5f5f5;
border: 1px solid #ededed;
}
a {
text-decoration: none;
color: #000;
}
input[type=text], input[type=password] {
padding: 0 10px;
width: 320px;
height: 38px;
font-size: 16px;
color: #555;
background-color: #fff;
background-image: none;
border: 1px solid #ccc;
border-radius: 4px;
}
label {
float: rihgt;
width: 100px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.edit-examinee label{
float: rihgt;
width: 130px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.loginform label {
float: rihgt;
width: 100px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.button {
display: inline-block;
zoom: 1;
padding: 12px 30px;
margin: 0;
cursor: pointer;
border: 1px solid #bbb;
overflow: visible;
font: bold 16px arial, helvetica, sans-serif;
text-decoration: none;
white-space: nowrap;
border-radius: 4px;
-moz-border-radius: 4px;
-webkit-border-radius: 4px;
}
.admin-login-button {
margin-right: 350px;
color: #333;
background-color: #fff;
border-color: #ccc;
}
.admin-login-button:hover {
color: #333;
background-color: #e6e6e6;
border-color: #adadad;
}
.admin-login-button:active {
color: #333;
background-color: #e6e6e6;
border-color: #adadad;
position: relative;
top: 2px;
text-shadow: none;
box-shadow: 0 1px 1px rgba(0, 0, 0, .3) inset;
}
You can also check the JSFiddle of the form.
I removed the floats (with a typo), set the margin to left on the .admin-login-button. I also added a media query for smaller screens.
https://jsfiddle.net/6p4v9hs6/7/
New CSS here:
.login-container {
margin-top: 100px;
margin-bottom: 50px;
margin-left: auto;
margin-right: auto;
width: 600px;
}
.loginform {
direction:RTL;
padding: 55px;
background-color: #fff;
border: 1px solid #eee;
border-bottom: 0px;
border-top: 0px;
}
.loginheader {
text-align: center;
background-color: #f5f5f5;
padding: 15px 0px;
border-radius: 10px 10px 0 0;
font-size: 30px;
}
.loginfooter {
padding: 15px 40px;
background-color: #f5f5f5;
border-radius: 0px 0px 10px 10px;
font-size: 18px;
text-align: center;
}
.loginheader, .loginfooter {
background-color: #f5f5f5;
border: 1px solid #ededed;
}
a {
text-decoration: none;
color: #000;
}
input[type=text], input[type=password] {
padding: 0 10px;
width: 320px;
height: 38px;
font-size: 16px;
color: #555;
background-color: #fff;
background-image: none;
border: 1px solid #ccc;
border-radius: 4px;
}
label {
/* float: rihgt; */
width: 100px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.edit-examinee label{
/* float: rihgt; */
width: 130px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.loginform label {
/* float: rihgt; */
width: 100px;
line-height: 40px;
padding-left: 10px;
font-size: 18px;
text-align: left;
display: inline-block;
margin: 10px 0px;
}
.button {
display: inline-block;
zoom: 1;
padding: 12px 30px;
margin: 0;
cursor: pointer;
border: 1px solid #bbb;
overflow: visible;
font: bold 16px arial, helvetica, sans-serif;
text-decoration: none;
white-space: nowrap;
border-radius: 4px;
-moz-border-radius: 4px;
-webkit-border-radius: 4px;
}
.admin-login-button {
margin-left: 350px;
color: #333;
background-color: #fff;
border-color: #ccc;
}
.admin-login-button:hover {
color: #333;
background-color: #e6e6e6;
border-color: #adadad;
}
.admin-login-button:active {
color: #333;
background-color: #e6e6e6;
border-color: #adadad;
position: relative;
top: 2px;
text-shadow: none;
box-shadow: 0 1px 1px rgba(0, 0, 0, .3) inset;
}
#media screen and (max-width: 540px) {
input[type=text], input[type=password] {
width: 90%;
}
}
Seems to work in both Safari and Firefox.

How to use a image as a button?

FIDDLE
As you can see that this is a button behind the image. I wanna remove that button. And use the images as button
.buttonup {
padding: 0px;
width: 25px;
cursor: pointer;
margin-right: 25px;
}
.buttondw {
width: 25px;
cursor: pointer;
margin-left: 25px;
}
#count {
display: inline-block;
border-radius: 0px;
background-color: #ff9933;
border: none;
color: #ffffff;
text-align: center;
font-size: 18px;
padding: 5px;
width: 50px;
margin-top: 0px;
}
<center>
<button class="buttonup" id="plus" style="vertical-align:middle"><span><img src="http://i.imgur.com/jWPUjR9.png"> </span> </button> <span id="count">0</span>
<button class="buttondw" id="minus" style="vertical-align:middle"><span><img src="http://i.imgur.com/Vu6tuf9.png"> </span> </button>
</center>
Use input type="image"
You will need to preventDefault() on the click event if you do not want to submit the page or the form it is in
.buttonup {
padding: 0px;
width: 25px;
cursor: pointer;
margin-right: 25px;
}
.buttondw {
width: 25px;
cursor: pointer;
margin-left: 25px;
}
#count {
display: inline-block;
border-radius: 0px;
background-color: #ff9933;
border: none;
color: #ffffff;
text-align: center;
font-size: 18px;
padding: 5px;
width: 50px;
margin-top: 0px;
}
<center>
<input type="image" class="buttonup" id="plus" style="vertical-align:middle" src="http://i.imgur.com/jWPUjR9.png" /> <span id="count">0</span>
<input type="image" class="buttondw" id="minus" style="vertical-align:middle" src="http://i.imgur.com/Vu6tuf9.png" />
</center>
you are very close actually, juste add the background:none and border:none on you class :
.buttonup {
padding: 0px;
width: 25px;
cursor: pointer;
margin-right: 25px;
background:none;
border:none;
}
change some css
.buttonup {
background: rgba(0, 0, 0, 0) none repeat scroll 0 0;
border: 0 none;
cursor: pointer;
padding: 0;
width: 45px;
}
.buttondw {
background: rgba(0, 0, 0, 0) none repeat scroll 0 0;
border: 0 none;
cursor: pointer;
padding: 0;
width: 45px;
}
https://fiddle.jshell.net/g6Lhurae/25/
Try this:
.buttonup {
padding: 0px;
text-align: center;
width: 50px;
cursor: pointer;
margin-right: 10px;
border:none;
background:none;
}
.buttondw {
width: 50px;
text-align: center;
cursor: pointer;
margin-left: 5px;
border:none;
background:none;
}
tip:don't use the center tag in your html; it's deprecated and not supported in html5. (I know this isn't the question but feel it should be pointed out).
So my css/html for you would be as follows (count css taken from mplungians post)
var counter = 0, // Try change this what ever you want
votePlus = counter + 1,
voteMinus = counter - 1;
function checkIfUserVoted() {
return localStorage.getItem("voted");
}
if (!localStorage.getItem("voted")) {
localStorage.setItem("voted", counter);
$("#count").text(counter);
}
$(".buttonup").click(function() {
var vote = checkIfUserVoted() != votePlus ? votePlus : counter;
localStorage.setItem("voted", vote);
$(this).next().text(vote);
});
$(".buttondw").on('click', function () {
var vote = checkIfUserVoted() != voteMinus ? voteMinus : counter;
localStorage.setItem("voted", vote);
$(this).prev().text(vote);
});
#buttons{margin-left: 35%; margin-right:35%;}
.buttonup {
padding: 0px;
width: 25px;
cursor: pointer;
margin-right: 25px;
}
.buttondw {
width: 25px;
cursor: pointer;
margin-left: 25px;
}
#count {
display: inline-block;
border-radius: 0px;
background-color: #ff9933;
border: none;
color: #ffffff;
text-align: center;
font-size: 18px;
padding: 5px;
width: 50px;
margin-top: 0px;
}
.buttondw {
width: 25px;
cursor: pointer;
margin-left: 25px;
}
#count {
display: inline-block;
border-radius: 0px;
background-color: #ff9933;
border: none;
color: #ffffff;
text-align: center;
font-size: 18px;
padding: 5px;
width: 50px;
margin-top: 0px;
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<div id="buttons">
<input type="image" class="buttonup" id="plus" style="vertical-align:middle" src="http://i.imgur.com/jWPUjR9.png" /> <span id="count">0</span>
<input type="image" class="buttondw" id="minus" style="vertical-align:middle" src="http://i.imgur.com/Vu6tuf9.png" />
</div>

Adding scroll bars to a div that does not have a set height

I have been having a problem with a little project I have been working on. I have a header and a footer and middle content. I want to have the middle content have a scrolling feature but I cannot set a definitive height. Is there a way to get around the required height for scroll to work?
#Bar, #sea {
-webkit-appearance: none;
-webkit-border-radius: 0;
}
#header {
font-size: 50px;
font-weight: bold;
text-align: center;
padding-top: 25px;
}
#form {
text-align: center;
}
#Bar {
height: 35px;
width: 400px;
font-size: 15px;
box-sizing: border-box;
border-style: solid;
vertical-align: top;
border-width: 1px;
border-color: #c7c7cd;
}
#Bar:focus {
outline: none;
border-style: solid;
border-width: 1px;
border-color: #3A89D8;
}
#sea:active {
outline: none;
border-width: 1px;
border-style: solid;
border-color: #3A89D8;
background-color: #1172d2;
}
#sea:focus {
outline: none;
border-style: solid;
border-width: 1px;
border-color: #3A89D8;
}
#sea {
background-color: #4199F0;
-moz-border-radius: 0px;
-webkit-border-radius: 0px;
border-radius: 0px;
height: 35px;
color: #ffffff;
font-weight: bold;
font-family: Arial;
border-style: solid;
border-width: 1px;
font-size: 15px;
text-decoration: none;
border-color: #3A89D8;
box-sizing: border-box;
vertical-align: top;
}
body {
margin: 0 auto;
font-family: Arial;
}
#hid {
visibility: hidden;
}
#NoteHolder {
padding-left: 125px;
padding-right: 125px;
overflow: auto;
}
#BarHold {
padding-top: 10px;
}
#SearchOP {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#NavSave {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#popupBoxOnePosition {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
.popupBoxWrapper {
width: 550px;
margin: 50px auto;
text-align: left;
}
.popupBoxContent {
background-color: #FFF;
padding: 15px;
overflow: hidden;
}
#popup-Sub {
-moz-border-radius: 0px;
-webkit-border-radius: 0px;
border-radius: 0px;
height: 45px;
background-color: #3232ff;
border-style: solid;
border-width: 1px;
font-family: Arial;
font-size: 15px;
float: right;
color: #FFFFFF;
border-color: #1919ff;
text-align: center;
width: 80px;
font-weight: bold;
}
.HeaderNote {
color: #7E7E7E;
font-family: Arial;
font-size: 12px;
}
#Col {
font-weight: bold;
}
table {
border: 1px solid #e0e0e0;
border-collapse: collapse;
margin: auto;
}
th, td {
border: 1px solid #e0e0e0;
border-collapse: collapse;
}
td {
padding: 5px;
text-align: left;
}
th {
background-color: #e6e6e6;
}
#Oper {
float: right;
padding-right: 15px;
cursor: default;
}
a:hover {
text-decoration: underline;
font-weight: bold;
}
#NoteAv {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#Settings {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#FirstVisit {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#MarkList {
vertical-align: middle;
position: fixed;
display: inline;
left: 0;
bottom: 0;
height: 56px;
width: 100%;
border-top-style: solid;
border-width: 1px;
border-color: #3A89D8;
background-color: #eff5f9;
overflow-x: hidden;
}
#MarkList > button {
height: 36px;
color: #39739d;
font-size: 18px;
text-align: center;
white-space: nowrap;
background: #E1ECF4;
border: 1px solid;
display: inline;
margin: 10px 10px 10px;
border-radius: 1px;
border-style: solid;
border-color: #39739d;
}
.YelColBox {
background-color: #F0F041;
}
.LastCol {
background-color: #F0F041;
}
.GreColBox {
background-color: #62ff62;
}
.BluColBox {
background-color: #4199F0;
}
.PurColBox {
background-color: #9941F0;
}
.RedColBox {
background-color: #F04141;
}
.OraColBox {
background-color: #F09941;
}
.ColorBox {
float: right;
width: 12px;
height: 12px;
margin: 5px 5px 5px 5px;
border-width: 1px;
border-style: solid;
border-color: rgba(0,0,0,.2);
}
<body onload="FirstVisit('Settings');">
<div style="height: 30%;">
<div>
<a id="Oper" onClick="toggle_visibility('NoteAv');">Notes</a><a id="Oper" onClick="toggle_visibility('Settings');">Settings</a>
<p id="header">Note Searcher</p>
</div>
<hr>
<p id="form">
<input onClick="this.setSelectionRange(0, this.value.length)" class="SearchInp" autocomplete="off" id="Bar" name="Input" type="text" placeholder="Removed JS for the fiddle.">
<input class="SearchInp" type="submit" id="sea" onClick="SetOff ()" value="Search">
<br>
<input id="Highlight" type="radio" name="textOp" checked>Highlight
<input id="Filter" type="radio" name="textOp">Filter
</p>
</div>
<div id="NoteHolder">
<p class="NoteOp">
Imagine if this filled up the whole text area.
</p>
</div>
<div id=Hid>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js"></script>
<script src="note.js"></script>
<footer id="MarkList">
</footer>
</body>
Setting the overflow property to scroll will show scrollbars (albeit disabled).
#Bar, #sea {
-webkit-appearance: none;
-webkit-border-radius: 0;
}
#header {
font-size: 50px;
font-weight: bold;
text-align: center;
padding-top: 25px;
}
#form {
text-align: center;
}
#Bar {
height: 35px;
width: 400px;
font-size: 15px;
box-sizing: border-box;
border-style: solid;
vertical-align: top;
border-width: 1px;
border-color: #c7c7cd;
}
#Bar:focus {
outline: none;
border-style: solid;
border-width: 1px;
border-color: #3A89D8;
}
#sea:active {
outline: none;
border-width: 1px;
border-style: solid;
border-color: #3A89D8;
background-color: #1172d2;
}
#sea:focus {
outline: none;
border-style: solid;
border-width: 1px;
border-color: #3A89D8;
}
#sea {
background-color: #4199F0;
-moz-border-radius: 0px;
-webkit-border-radius: 0px;
border-radius: 0px;
height: 35px;
color: #ffffff;
font-weight: bold;
font-family: Arial;
border-style: solid;
border-width: 1px;
font-size: 15px;
text-decoration: none;
border-color: #3A89D8;
box-sizing: border-box;
vertical-align: top;
}
body {
margin: 0 auto;
font-family: Arial;
}
#hid {
visibility: hidden;
}
#NoteHolder {
padding-left: 125px;
padding-right: 125px;
overflow: scroll;
}
#BarHold {
padding-top: 10px;
}
#SearchOP {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#NavSave {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#popupBoxOnePosition {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
.popupBoxWrapper {
width: 550px;
margin: 50px auto;
text-align: left;
}
.popupBoxContent {
background-color: #FFF;
padding: 15px;
overflow: hidden;
}
#popup-Sub {
-moz-border-radius: 0px;
-webkit-border-radius: 0px;
border-radius: 0px;
height: 45px;
background-color: #3232ff;
border-style: solid;
border-width: 1px;
font-family: Arial;
font-size: 15px;
float: right;
color: #FFFFFF;
border-color: #1919ff;
text-align: center;
width: 80px;
font-weight: bold;
}
.HeaderNote {
color: #7E7E7E;
font-family: Arial;
font-size: 12px;
}
#Col {
font-weight: bold;
}
table {
border: 1px solid #e0e0e0;
border-collapse: collapse;
margin: auto;
}
th, td {
border: 1px solid #e0e0e0;
border-collapse: collapse;
}
td {
padding: 5px;
text-align: left;
}
th {
background-color: #e6e6e6;
}
#Oper {
float: right;
padding-right: 15px;
cursor: default;
}
a:hover {
text-decoration: underline;
font-weight: bold;
}
#NoteAv {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#Settings {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#FirstVisit {
top: 0;
left: 0;
position: fixed;
width: 100%;
height: 120%;
background-color: rgba(0,0,0,0.5);
display: none;
}
#MarkList {
vertical-align: middle;
position: fixed;
display: inline;
left: 0;
bottom: 0;
height: 56px;
width: 100%;
border-top-style: solid;
border-width: 1px;
border-color: #3A89D8;
background-color: #eff5f9;
overflow-x: hidden;
}
#MarkList > button {
height: 36px;
color: #39739d;
font-size: 18px;
text-align: center;
white-space: nowrap;
background: #E1ECF4;
border: 1px solid;
display: inline;
margin: 10px 10px 10px;
border-radius: 1px;
border-style: solid;
border-color: #39739d;
}
.YelColBox {
background-color: #F0F041;
}
.LastCol {
background-color: #F0F041;
}
.GreColBox {
background-color: #62ff62;
}
.BluColBox {
background-color: #4199F0;
}
.PurColBox {
background-color: #9941F0;
}
.RedColBox {
background-color: #F04141;
}
.OraColBox {
background-color: #F09941;
}
.ColorBox {
float: right;
width: 12px;
height: 12px;
margin: 5px 5px 5px 5px;
border-width: 1px;
border-style: solid;
border-color: rgba(0,0,0,.2);
}
<body onload="FirstVisit('Settings');">
<div style="height: 30%;">
<div>
<a id="Oper" onClick="toggle_visibility('NoteAv');">Notes</a><a id="Oper" onClick="toggle_visibility('Settings');">Settings</a>
<p id="header">Note Searcher</p>
</div>
<hr>
<p id="form">
<input onClick="this.setSelectionRange(0, this.value.length)" class="SearchInp" autocomplete="off" id="Bar" name="Input" type="text" placeholder="Removed JS for the fiddle.">
<input class="SearchInp" type="submit" id="sea" onClick="SetOff ()" value="Search">
<br>
<input id="Highlight" type="radio" name="textOp" checked>Highlight
<input id="Filter" type="radio" name="textOp">Filter
</p>
</div>
<div id="NoteHolder">
<p class="NoteOp">
Imagine if this filled up the whole text area.
</p>
</div>
<div id=Hid>
</div>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js"></script>
<script src="note.js"></script>
<footer id="MarkList">
</footer>
</body>
A screenshot of the scrollbars:

How can I delete these arrows?

I have this site:
http://test2.dac-proiect.ro/wp/?page_id=6
I want to remove the arrows in the picture below.
http://i61.tinypic.com/rhvgxh.png
You must add the product to cart to see those arrows
Code HTML:
<div class="cart-number">
<span></span>
<div class="quantity buttons_added"><input type="button" value="-" class="minus"><input type="number" step="1" name="cart[d3d9446802a44259755d38e6d163e820][qty]" value="1" title="Quantity" class="input-text qty text" size="4"><input type="button" value="+" class="plus"></div>
</div>
Code CSS:
.quantity {
width: auto;
position: relative;
margin: 0 auto;
overflow: hidden;
zoom: 1;
}
.quantity input.qty {
float: left;
width: 45px;
height: 38px;
text-align: center;
border-bottom-right-radius: 0;
border-top-right-radius: 0;
border-bottom-left-radius: 0;
border-top-left-radius: 0;
padding: 0;
font-weight: bold;
-moz-appearance: textfield;
}
.quantity input.qty:focus:focus {
border-color: #66afe9;
outline: 0;
-webkit-box-shadow: none;
box-shadow: none;
}
.quantity .plus, .quantity .minus {
background: #fff;
float: left;
display: block;
padding: 0;
margin: 0;
vertical-align: text-top;
text-decoration: none;
overflow: visible;
text-decoration: none;
cursor: pointer;
line-height: 13px;
font-size: 12px;
color: #666666;
border: 1px solid #e5e5e5;
text-align: center;
width: 45px;
height: 38px;
}
.quantity .plus {
border-left: none;
top: 0;
border-bottom-right-radius: 0;
border-bottom-left-radius: 0;
right: 0;
}
.quantity .minus {
border-right: none;
bottom: 0;
right: 0;
border-top-right-radius: 0;
border-top-left-radius: 0;
}
How can I solve this problem?
I can not figure out where they come from those arrows
Thanks in advance!
It all depends on the input type, you want to use this bit of CSS to hide it.
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
-webkit-appearance: none;
margin: 0;}
input[type="number"] {
-moz-appearance: textfield;}
Cheers

Arrow pointing downwards in div

I don't know how to put this question but here's what I wanna do. I have made a login form. I want the bottom of my login form to look something like this
So far I have this:
My css:
/***** Login *******/
fieldset {
border: none;
margin: 0;
}
input {
border: none;
font-family: inherit;
font-size: inherit;
margin: 0;
-webkit-appearance: none;
}
input:focus {
outline: none;
}
input[type="submit"] { cursor: pointer; }
/* ---------- LOGIN-FORM ---------- */
#login-form {
margin: 10px;
width: 300px;
border: 1px solid #ea6e10;
vertical-align: middle;
}
#login-form h3 {
background-color:#ea6e10;
color: #fff;
font-size: 14px;
margin-top: 0;
padding: 20px;
text-align: right;
}
#login-form fieldset {
background: #fff;
border: 1px #ea6e10;
padding: 20px;
position: relative;
}
#login-form input {
font-size: 14px;
}
#login-form input[type="username"],
#login-form input[type="password"] {
background: #dcdcdc;
padding: 12px 10px;
width: 238px;
margin-top: 5px;
}
#login-form input[type="username"] {
}
#login-form input[type="password"] {
border-radius: 0px 0px 3px 3px;
}
#login-form input[type="submit"] {
background: #ea6e10;
text-align: center;
color: #fff;
float: left;
font-weight: bold;
margin-top: 5px;
padding: 12px 20px;
width: 100%;
}
#login-form input[type="submit"]:hover {
background: #ea6e10;
}
/***** Login *******/
fieldset {
border: none;
margin: 0;
}
input {
border: none;
font-family: inherit;
font-size: inherit;
margin: 0;
-webkit-appearance: none;
}
input:focus {
outline: none;
}
input[type="submit"] { cursor: pointer; }
/* ---------- LOGIN-FORM ---------- */
#login-form {
margin: 10px;
width: 300px;
border: 1px solid #ea6e10;
vertical-align: middle;
}
#login-form h3 {
background-color:#ea6e10;
color: #fff;
font-size: 14px;
margin-top: 0;
padding: 20px;
text-align: right;
}
#login-form fieldset {
background: #fff;
border: 1px #ea6e10;
padding: 20px;
position: relative;
}
#login-form input {
font-size: 14px;
}
#login-form input[type="username"],
#login-form input[type="password"] {
background: #dcdcdc;
padding: 12px 10px;
width: 238px;
margin-top: 5px;
}
#login-form input[type="username"] {
}
#login-form input[type="password"] {
border-radius: 0px 0px 3px 3px;
}
#login-form input[type="submit"] {
background: #ea6e10;
text-align: center;
color: #fff;
float: left;
font-weight: bold;
margin-top: 5px;
padding: 12px 20px;
width: 100%;
}
#login-form input[type="submit"]:hover {
background: #ea6e10;
}
<div id="login-form" style="float:left;">
<h3>Login</h3>
<fieldset>
<input type="username" required value="username" onBlur="if(this.value=='')this.value='username'" onFocus="if(this.value=='username')this.value='' "> <!-- JS because of IE support; better: placeholder="username" -->
<input type="password" required value="Password" onBlur="if(this.value=='')this.value='Password'" onFocus="if(this.value=='Password')this.value='' "> <!-- JS because of IE support; better: placeholder="Password" -->
<p>Forgot Password?</p>
<input type="submit" value="Login">
</form>
</fieldset>
</div>
Change your CSS like this:
/***** Login *******/
fieldset {
border: none;
margin: 0;
}
input {
border: none;
font-family: inherit;
font-size: inherit;
margin: 0;
-webkit-appearance: none;
}
input:focus {
outline: none;
}
input[type="submit"] {
cursor: pointer;
}
/* ---------- LOGIN-FORM ---------- */
#login-form {
margin: 10px;
width: 300px;
vertical-align: middle;
position: relative;
background: #f9f9f9;
border: 1px solid #ea6e10;
}
#login-form:after, #login-form:before {
top: 100%;
left: 50%;
border: solid transparent;
content:" ";
height: 0;
width: 0;
position: absolute;
pointer-events: none;
}
#login-form:after {
border-color: rgba(249, 249, 249, 0);
border-top-color: #f9f9f9;
border-width: 15px;
margin-left: -15px;
}
#login-form:before {
border-color: rgba(255, 102, 0, 0);
border-top-color: #ea6e10;
border-width: 16px;
margin-left: -16px;
}
#login-form h3 {
background-color:#ea6e10;
color: #fff;
font-size: 14px;
margin-top: 0;
padding: 20px;
text-align: right;
}
#login-form fieldset {
background: #fff;
border: 1px #ea6e10;
padding: 20px;
position: relative;
}
#login-form input {
font-size: 14px;
}
#login-form input[type="username"], #login-form input[type="password"] {
background: #dcdcdc;
padding: 12px 10px;
width: 238px;
margin-top: 5px;
}
#login-form input[type="username"] {
}
#login-form input[type="password"] {
border-radius: 0px 0px 3px 3px;
}
#login-form input[type="submit"] {
background: #ea6e10;
text-align: center;
color: #fff;
float: left;
font-weight: bold;
margin-top: 5px;
padding: 12px 20px;
width: 100%;
}
#login-form input[type="submit"]:hover {
background: #ea6e10;
}
See forked CodePen
You can use this is a bubble generator:
.bubble {
position: relative;
width: 250px;
padding: 0px;
background: #FFFFFF;
-webkit-border-radius: 10px;
-moz-border-radius: 10px;
border-radius: 10px;
border: #ea6e10 solid 2px;
}
.bubble:after {
content:'';
position: absolute;
border-style: solid;
border-width: 15px 15px 0;
border-color: #FFFFFF transparent;
display: block;
width: 0;
z-index: 1;
bottom: -15px;
left: 136px;
}
.bubble:before {
content:'';
position: absolute;
border-style: solid;
border-width: 16px 16px 0;
border-color: #ea6e10 transparent;
display: block;
width: 0;
z-index: 0;
bottom: -17px;
left: 135px;
}
And apply this class in your container element. In your case:
<div id="login-form" class="bubble" style="float:left;">
fiddle
Here's your change in an updated CodePen.
And here's what we did:
CSS
#login-form {
margin: 10px;
width: 300px;
border: 1px solid #ea6e10;
vertical-align: middle;
position: relative;
}
#login-form:after {
position: absolute;
content: ' ';
transform: rotate(45deg) translate(-50%, -5px);
height:30px;
width:30px;
top: 100%;
left: 50%;
background-color: white;
border-color: #ea6e10;
border-width: 1px;
border-style: solid;
border-top: none;
border-left: none;
pointer-events: none;
}
We allow the pseudo-element after to be appropriately positioned by setting the #login-form to position:relative. The important part of this is the #login-form:after part, though. We're creating a pseudo-element that exists outside the normal document object model to provide the stylistic element. We take this, define it as a 30px x 30px box, give it a white background and an orange border, and put it smack dab in the bottom middle of your parent element #login-form. Then, we use transforms to rotate it 45 degrees and scoot it up 5 pixels to meet the bottom border of your parent element.
This will not work in IE 9 and below
We need to do some clever things with borders for IE 9 and under. Here's the change for that scenario:
CSS
#login-form {
position: relative;
}
#login-form:before, #login-form:after {
position: absolute;
top: 100%;
left: 50%;
content: ' ';
}
#login-form:before {
border-top: solid 15px white;
border-left: solid 15px transparent;
border-right: solid 15px transparent;
margin-left: -15px;
}
#login-form:after {
border-top: solid 17px #ea6e10;
border-left: solid 17px transparent;
border-right: solid 17px transparent;
margin-left: -17px;
}