I want to add a Js login page on my site. But with var=prompt("x","x"); in js show only one input box in my site . I want a Js code that pop up a box that can be use as a login page.
or give me a code that can disply two input field in this code. -
<!DOCTYPE html>
-
<html>
-
<body>
-
-
<p>Click the button to demonstrate the prompt box.</p>
-
-
<button onclick="myFunction()">Try it</button>
-
-
<p id="demo"></p>
-
-
<script>
-
function myFunction() {
-
var person = prompt("Please enter your name", "Harry Potter");
-
-
if (person != null) {
-
document.getElementById("demo").innerHTML =
-
"Hello " + person + "! How are you today?";
-
}
-
}
-
</script>
-
-
</body>
-
</html>
4 1629
kindly check out jQueryUI, this has such prompt boxes.
I'm not sure I understand the need for a library solution
when you could create a quick and dirty solution like this... -
<!DOCTYPE html>
-
<html>
-
<style type="text/css">
-
#login {
-
display:none; z-index:5;
-
height:200px; width:300px;
-
position:absolute; top:200px; left:300px;
-
}
-
</style>
-
<body>
-
-
<p>Click the button to demonstrate the prompt box.</p>
-
-
<button onclick="myFunction()">Try it</button>
-
-
<div id="login">
-
Login: <input type="text" id="loginName" value=""><p>
-
Password: <input type="password" id="loginPswd" value=""><p>
-
<button onclick="Submit()">Submit</button>
-
<button onclick="Cancel()">Cancel</button>
-
</div>
-
-
<p id="demo"></p>
-
-
<script>
-
function myFunction() {
-
document.getElementById('loginName').value = '';
-
document.getElementById('loginPswd').value = '';
-
document.getElementById('login').style.display = 'block';
-
}
-
function Submit() {
-
document.getElementById('login').style.display = 'none';
-
alert('Checks of login information performed here');
-
}
-
function Cancel() {
-
document.getElementById('loginName').value = '';
-
document.getElementById('loginPswd').value = '';
-
document.getElementById('login').style.display = 'none';
-
}
-
</script>
-
-
</body>
-
</html>
-
You can try this code. -
<!DOCTYPE html>
-
<html>
-
<title>Zick Login Sample</title>
-
<head>
-
<style>
-
html, body{padding:0px; margin:0px;}
-
#loginBG{
-
background:rgba(1,1,1,0.3);
-
height:100%;
-
width:100%;
-
position:fixed;
-
float:none;
-
z-index:1;
-
top:0;
-
font-family:Arial, Helvetica, sans-serif;
-
}
-
.loginwrapper{
-
background:#FFF;
-
padding:10px;
-
margin: 0px auto;
-
width: 400px;
-
margin-top:20px;
-
border-radius:5px;
-
box-shadow:0px 2px 2px rgba(1,1,1,0.4);
-
}
-
.fieldset{
-
padding:20px;
-
border-radius:5px;
-
border:1px solid #333;
-
}
-
.fieldset legend{font-weight:bold; padding: 5px;}
-
.fieldset table{paddng:0px; margin:0px; margin-bottom:10px; width:100%;}
-
.fieldset table tr td{
-
font-weight:bold;
-
padding:0px;
-
}
-
.close {
-
float: right;
-
font-size: 20px;
-
font-weight: bold;
-
line-height: 20px;
-
color: #000000;
-
text-shadow: 0 1px 0 #ffffff;
-
opacity: 0.2;
-
filter: alpha(opacity=20);
-
}
-
.close:hover,
-
.close:focus {
-
color: #000000;
-
text-decoration: none;
-
cursor: pointer;
-
opacity: 0.4;
-
filter: alpha(opacity=40);
-
}
-
button.close {
-
padding: 0;
-
cursor: pointer;
-
background: transparent;
-
border: 0;
-
-webkit-appearance: none;
-
}
-
.btn {
-
display: inline-block;
-
*display: inline;
-
padding: 4px 12px;
-
margin-bottom: 0;
-
*margin-left: .3em;
-
font-size: 14px;
-
line-height: 20px;
-
color: #333333;
-
text-align: center;
-
text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75);
-
vertical-align: middle;
-
cursor: pointer;
-
background-color: #f5f5f5;
-
*background-color: #e6e6e6;
-
background-image: -moz-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#e6e6e6));
-
background-image: -webkit-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: -o-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: linear-gradient(to bottom, #ffffff, #e6e6e6);
-
background-repeat: repeat-x;
-
border: 1px solid #cccccc;
-
*border: 0;
-
border-color: #e6e6e6 #e6e6e6 #bfbfbf;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
border-bottom-color: #b3b3b3;
-
-webkit-border-radius: 4px;
-
-moz-border-radius: 4px;
-
border-radius: 4px;
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
*zoom: 1;
-
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
-moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
}
-
.btn:hover,
-
.btn:focus,
-
.btn:active,
-
.btn.active,
-
.btn.disabled,
-
.btn[disabled] {
-
color: #333333;
-
background-color: #e6e6e6;
-
*background-color: #d9d9d9;
-
}
-
.btn:active,
-
.btn.active {
-
background-color: #cccccc \9;
-
}
-
.btn:first-child {
-
*margin-left: 0;
-
}
-
.btn:hover,
-
.btn:focus {
-
color: #333333;
-
text-decoration: none;
-
background-position: 0 -15px;
-
-webkit-transition: background-position 0.1s linear;
-
-moz-transition: background-position 0.1s linear;
-
-o-transition: background-position 0.1s linear;
-
transition: background-position 0.1s linear;
-
}
-
.btn:focus {
-
outline: thin dotted #333;
-
outline: 5px auto -webkit-focus-ring-color;
-
outline-offset: -2px;
-
}
-
.btn.active,
-
.btn:active {
-
background-image: none;
-
outline: 0;
-
-webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
-moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
}
-
.btn-primary.active,
-
.btn-warning.active,
-
.btn-danger.active,
-
.btn-success.active,
-
.btn-info.active,
-
.btn-inverse.active {
-
color: rgba(255, 255, 255, 0.75);
-
}
-
.btn-primary {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #006dcc;
-
*background-color: #0044cc;
-
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
-
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
-
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
-
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
-
background-repeat: repeat-x;
-
border-color: #0044cc #0044cc #002a80;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0044cc', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-primary:hover,
-
.btn-primary:focus,
-
.btn-primary:active,
-
.btn-primary.active,
-
.btn-primary.disabled,
-
.btn-primary[disabled] {
-
color: #ffffff;
-
background-color: #0044cc;
-
*background-color: #003bb3;
-
}
-
.btn-primary:active,
-
.btn-primary.active {
-
background-color: #003399 \9;
-
}
-
.btn-warning {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #faa732;
-
*background-color: #f89406;
-
background-image: -moz-linear-gradient(top, #fbb450, #f89406);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406));
-
background-image: -webkit-linear-gradient(top, #fbb450, #f89406);
-
background-image: -o-linear-gradient(top, #fbb450, #f89406);
-
background-image: linear-gradient(to bottom, #fbb450, #f89406);
-
background-repeat: repeat-x;
-
border-color: #f89406 #f89406 #ad6704;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-warning:hover,
-
.btn-warning:focus,
-
.btn-warning:active,
-
.btn-warning.active,
-
.btn-warning.disabled,
-
.btn-warning[disabled] {
-
color: #ffffff;
-
background-color: #f89406;
-
*background-color: #df8505;
-
}
-
.btn-warning:active,
-
.btn-warning.active {
-
background-color: #c67605 \9;
-
}
-
.btn-danger {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #da4f49;
-
*background-color: #bd362f;
-
background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f));
-
background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: -o-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: linear-gradient(to bottom, #ee5f5b, #bd362f);
-
background-repeat: repeat-x;
-
border-color: #bd362f #bd362f #802420;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-danger:hover,
-
.btn-danger:focus,
-
.btn-danger:active,
-
.btn-danger.active,
-
.btn-danger.disabled,
-
.btn-danger[disabled] {
-
color: #ffffff;
-
background-color: #bd362f;
-
*background-color: #a9302a;
-
}
-
.btn-danger:active,
-
.btn-danger.active {
-
background-color: #942a25 \9;
-
}
-
.btn-success {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #5bb75b;
-
*background-color: #51a351;
-
background-image: -moz-linear-gradient(top, #62c462, #51a351);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#51a351));
-
background-image: -webkit-linear-gradient(top, #62c462, #51a351);
-
background-image: -o-linear-gradient(top, #62c462, #51a351);
-
background-image: linear-gradient(to bottom, #62c462, #51a351);
-
background-repeat: repeat-x;
-
border-color: #51a351 #51a351 #387038;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff51a351', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-success:hover,
-
.btn-success:focus,
-
.btn-success:active,
-
.btn-success.active,
-
.btn-success.disabled,
-
.btn-success[disabled] {
-
color: #ffffff;
-
background-color: #51a351;
-
*background-color: #499249;
-
}
-
.btn-success:active,
-
.btn-success.active {
-
background-color: #408140 \9;
-
}
-
.btn-info {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #49afcd;
-
*background-color: #2f96b4;
-
background-image: -moz-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#2f96b4));
-
background-image: -webkit-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: -o-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: linear-gradient(to bottom, #5bc0de, #2f96b4);
-
background-repeat: repeat-x;
-
border-color: #2f96b4 #2f96b4 #1f6377;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2f96b4', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-info:hover,
-
.btn-info:focus,
-
.btn-info:active,
-
.btn-info.active,
-
.btn-info.disabled,
-
.btn-info[disabled] {
-
color: #ffffff;
-
background-color: #2f96b4;
-
*background-color: #2a85a0;
-
}
-
.btn-info:active,
-
.btn-info.active {
-
background-color: #24748c \9;
-
}
-
.btn-inverse {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #363636;
-
*background-color: #222222;
-
background-image: -moz-linear-gradient(top, #444444, #222222);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#444444), to(#222222));
-
background-image: -webkit-linear-gradient(top, #444444, #222222);
-
background-image: -o-linear-gradient(top, #444444, #222222);
-
background-image: linear-gradient(to bottom, #444444, #222222);
-
background-repeat: repeat-x;
-
border-color: #222222 #222222 #000000;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff444444', endColorstr='#ff222222', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-inverse:hover,
-
.btn-inverse:focus,
-
.btn-inverse:active,
-
.btn-inverse.active,
-
.btn-inverse.disabled,
-
.btn-inverse[disabled] {
-
color: #ffffff;
-
background-color: #222222;
-
*background-color: #151515;
-
}
-
.btn-inverse:active,
-
.btn-inverse.active {
-
background-color: #080808 \9;
-
}
-
button.btn,
-
input[type="submit"].btn {
-
*padding-top: 3px;
-
*padding-bottom: 3px;
-
}
-
button.btn::-moz-focus-inner,
-
input[type="submit"].btn::-moz-focus-inner {
-
padding: 0;
-
border: 0;
-
}
-
button.btn.btn-large,
-
input[type="submit"].btn.btn-large {
-
*padding-top: 7px;
-
*padding-bottom: 7px;
-
}
-
button.btn.btn-small,
-
input[type="submit"].btn.btn-small {
-
*padding-top: 3px;
-
*padding-bottom: 3px;
-
}
-
button.btn.btn-mini,
-
input[type="submit"].btn.btn-mini {
-
*padding-top: 1px;
-
*padding-bottom: 1px;
-
}
-
input[type="text"],
-
input[type="password"]{
-
display: inline-block;
-
height: 20px;
-
padding: 4px 6px;
-
margin-bottom: 10px;
-
font-size: 14px;
-
line-height: 20px;
-
color: #555555;
-
vertical-align: middle;
-
-webkit-border-radius: 4px;
-
-moz-border-radius: 4px;
-
border-radius: 4px;
-
}
-
input[type="text"],
-
input[type="password"]{
-
background-color: #ffffff;
-
border: 1px solid #cccccc;
-
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
-webkit-transition: border linear 0.2s, box-shadow linear 0.2s;
-
-moz-transition: border linear 0.2s, box-shadow linear 0.2s;
-
-o-transition: border linear 0.2s, box-shadow linear 0.2s;
-
transition: border linear 0.2s, box-shadow linear 0.2s;
-
}
-
input[type="text"]:focus,
-
input[type="password"]:focus{
-
border-color: rgba(82, 168, 236, 0.8);
-
outline: 0;
-
outline: thin dotted \9;
-
/* IE6-9 */
-
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
}
-
.fullwidth{
-
width:100%;
-
}
-
</style>
-
<script>
-
function Login()
-
{
-
var usrnm = document.getElementById("usrnm").value;
-
var pwd = document.getElementById("pwd").value;
-
-
if(usrnm != "" && pwd != "")
-
{
-
document.getElementById("demo").innerHTML = "Hello " + usrnm + "! How are you today? <br> Your password is "+pwd;
-
closemodal();//close the login modal
-
}
-
}
-
function showmodal(){
-
document.getElementById("loginBG").style.display="block";
-
}
-
function closemodal(){
-
document.getElementById("loginBG").style.display="none";
-
}
-
</script>
-
</head>
-
<body>
-
-
<p>Click the button to demonstrate the prompt box.</p>
-
<button onclick="showmodal()">Try it</button>
-
<div id="demo"></div>
-
-
<div id="loginBG" style="display:none;">
-
<div id="loginwrapper" class="loginwrapper">
-
<div align="right" style="float:right;margin-right:7px; margin-bottom:6px; margin-top:-2px;">
-
<button type="button" class="close" onclick="closemodal()" style="position:absolute;" title="Close">
-
<span aria-hidden="true">×</span>
-
</button>
-
</div>
-
<div style="clear:both; padding:0px;"></div>
-
<fieldset class="fieldset">
-
<legend>LOGIN</legend>
-
<form method="post" action="javascript:;">
-
<table>
-
<tr>
-
<td style="width:1%;">Username: </td>
-
<td>
-
<input type="text" id="usrnm" style="width:95%;">
-
</td>
-
</tr>
-
<tr>
-
<td>Password: </td>
-
<td>
-
<input type="password" id="pwd" style="width:95%;">
-
</td>
-
</tr>
-
</table>
-
<input type="submit" id="login" value="Login" class="btn btn-primary fullwidth" onClick="Login()">
-
</form>
-
</fieldset>
-
</div>
-
</div>
-
</body>
-
</html>
-
You can try this code. -
<!DOCTYPE html>
-
<html>
-
<title>Zick Login Sample</title>
-
<head>
-
<style>
-
html, body{padding:0px; margin:0px;}
-
#loginBG{
-
background:rgba(1,1,1,0.3);
-
height:100%;
-
width:100%;
-
position:fixed;
-
float:none;
-
z-index:1;
-
top:0;
-
font-family:Arial, Helvetica, sans-serif;
-
}
-
.loginwrapper{
-
background:#FFF;
-
padding:10px;
-
margin: 0px auto;
-
width: 400px;
-
margin-top:20px;
-
border-radius:5px;
-
box-shadow:0px 2px 2px rgba(1,1,1,0.4);
-
}
-
.fieldset{
-
padding:20px;
-
border-radius:5px;
-
border:1px solid #333;
-
}
-
.fieldset legend{font-weight:bold; padding: 5px;}
-
.fieldset table{paddng:0px; margin:0px; margin-bottom:10px; width:100%;}
-
.fieldset table tr td{
-
font-weight:bold;
-
padding:0px;
-
}
-
.close {
-
float: right;
-
font-size: 20px;
-
font-weight: bold;
-
line-height: 20px;
-
color: #000000;
-
text-shadow: 0 1px 0 #ffffff;
-
opacity: 0.2;
-
filter: alpha(opacity=20);
-
}
-
.close:hover,
-
.close:focus {
-
color: #000000;
-
text-decoration: none;
-
cursor: pointer;
-
opacity: 0.4;
-
filter: alpha(opacity=40);
-
}
-
button.close {
-
padding: 0;
-
cursor: pointer;
-
background: transparent;
-
border: 0;
-
-webkit-appearance: none;
-
}
-
.btn {
-
display: inline-block;
-
*display: inline;
-
padding: 4px 12px;
-
margin-bottom: 0;
-
*margin-left: .3em;
-
font-size: 14px;
-
line-height: 20px;
-
color: #333333;
-
text-align: center;
-
text-shadow: 0 1px 1px rgba(255, 255, 255, 0.75);
-
vertical-align: middle;
-
cursor: pointer;
-
background-color: #f5f5f5;
-
*background-color: #e6e6e6;
-
background-image: -moz-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ffffff), to(#e6e6e6));
-
background-image: -webkit-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: -o-linear-gradient(top, #ffffff, #e6e6e6);
-
background-image: linear-gradient(to bottom, #ffffff, #e6e6e6);
-
background-repeat: repeat-x;
-
border: 1px solid #cccccc;
-
*border: 0;
-
border-color: #e6e6e6 #e6e6e6 #bfbfbf;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
border-bottom-color: #b3b3b3;
-
-webkit-border-radius: 4px;
-
-moz-border-radius: 4px;
-
border-radius: 4px;
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
*zoom: 1;
-
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
-moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 1px 2px rgba(0, 0, 0, 0.05);
-
}
-
.btn:hover,
-
.btn:focus,
-
.btn:active,
-
.btn.active,
-
.btn.disabled,
-
.btn[disabled] {
-
color: #333333;
-
background-color: #e6e6e6;
-
*background-color: #d9d9d9;
-
}
-
.btn:active,
-
.btn.active {
-
background-color: #cccccc \9;
-
}
-
.btn:first-child {
-
*margin-left: 0;
-
}
-
.btn:hover,
-
.btn:focus {
-
color: #333333;
-
text-decoration: none;
-
background-position: 0 -15px;
-
-webkit-transition: background-position 0.1s linear;
-
-moz-transition: background-position 0.1s linear;
-
-o-transition: background-position 0.1s linear;
-
transition: background-position 0.1s linear;
-
}
-
.btn:focus {
-
outline: thin dotted #333;
-
outline: 5px auto -webkit-focus-ring-color;
-
outline-offset: -2px;
-
}
-
.btn.active,
-
.btn:active {
-
background-image: none;
-
outline: 0;
-
-webkit-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
-moz-box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
-
}
-
.btn-primary.active,
-
.btn-warning.active,
-
.btn-danger.active,
-
.btn-success.active,
-
.btn-info.active,
-
.btn-inverse.active {
-
color: rgba(255, 255, 255, 0.75);
-
}
-
.btn-primary {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #006dcc;
-
*background-color: #0044cc;
-
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
-
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
-
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
-
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
-
background-repeat: repeat-x;
-
border-color: #0044cc #0044cc #002a80;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0088cc', endColorstr='#ff0044cc', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-primary:hover,
-
.btn-primary:focus,
-
.btn-primary:active,
-
.btn-primary.active,
-
.btn-primary.disabled,
-
.btn-primary[disabled] {
-
color: #ffffff;
-
background-color: #0044cc;
-
*background-color: #003bb3;
-
}
-
.btn-primary:active,
-
.btn-primary.active {
-
background-color: #003399 \9;
-
}
-
.btn-warning {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #faa732;
-
*background-color: #f89406;
-
background-image: -moz-linear-gradient(top, #fbb450, #f89406);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fbb450), to(#f89406));
-
background-image: -webkit-linear-gradient(top, #fbb450, #f89406);
-
background-image: -o-linear-gradient(top, #fbb450, #f89406);
-
background-image: linear-gradient(to bottom, #fbb450, #f89406);
-
background-repeat: repeat-x;
-
border-color: #f89406 #f89406 #ad6704;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffbb450', endColorstr='#fff89406', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-warning:hover,
-
.btn-warning:focus,
-
.btn-warning:active,
-
.btn-warning.active,
-
.btn-warning.disabled,
-
.btn-warning[disabled] {
-
color: #ffffff;
-
background-color: #f89406;
-
*background-color: #df8505;
-
}
-
.btn-warning:active,
-
.btn-warning.active {
-
background-color: #c67605 \9;
-
}
-
.btn-danger {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #da4f49;
-
*background-color: #bd362f;
-
background-image: -moz-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#ee5f5b), to(#bd362f));
-
background-image: -webkit-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: -o-linear-gradient(top, #ee5f5b, #bd362f);
-
background-image: linear-gradient(to bottom, #ee5f5b, #bd362f);
-
background-repeat: repeat-x;
-
border-color: #bd362f #bd362f #802420;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffee5f5b', endColorstr='#ffbd362f', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-danger:hover,
-
.btn-danger:focus,
-
.btn-danger:active,
-
.btn-danger.active,
-
.btn-danger.disabled,
-
.btn-danger[disabled] {
-
color: #ffffff;
-
background-color: #bd362f;
-
*background-color: #a9302a;
-
}
-
.btn-danger:active,
-
.btn-danger.active {
-
background-color: #942a25 \9;
-
}
-
.btn-success {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #5bb75b;
-
*background-color: #51a351;
-
background-image: -moz-linear-gradient(top, #62c462, #51a351);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#62c462), to(#51a351));
-
background-image: -webkit-linear-gradient(top, #62c462, #51a351);
-
background-image: -o-linear-gradient(top, #62c462, #51a351);
-
background-image: linear-gradient(to bottom, #62c462, #51a351);
-
background-repeat: repeat-x;
-
border-color: #51a351 #51a351 #387038;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff62c462', endColorstr='#ff51a351', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-success:hover,
-
.btn-success:focus,
-
.btn-success:active,
-
.btn-success.active,
-
.btn-success.disabled,
-
.btn-success[disabled] {
-
color: #ffffff;
-
background-color: #51a351;
-
*background-color: #499249;
-
}
-
.btn-success:active,
-
.btn-success.active {
-
background-color: #408140 \9;
-
}
-
.btn-info {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #49afcd;
-
*background-color: #2f96b4;
-
background-image: -moz-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#5bc0de), to(#2f96b4));
-
background-image: -webkit-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: -o-linear-gradient(top, #5bc0de, #2f96b4);
-
background-image: linear-gradient(to bottom, #5bc0de, #2f96b4);
-
background-repeat: repeat-x;
-
border-color: #2f96b4 #2f96b4 #1f6377;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff2f96b4', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-info:hover,
-
.btn-info:focus,
-
.btn-info:active,
-
.btn-info.active,
-
.btn-info.disabled,
-
.btn-info[disabled] {
-
color: #ffffff;
-
background-color: #2f96b4;
-
*background-color: #2a85a0;
-
}
-
.btn-info:active,
-
.btn-info.active {
-
background-color: #24748c \9;
-
}
-
.btn-inverse {
-
color: #ffffff;
-
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
-
background-color: #363636;
-
*background-color: #222222;
-
background-image: -moz-linear-gradient(top, #444444, #222222);
-
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#444444), to(#222222));
-
background-image: -webkit-linear-gradient(top, #444444, #222222);
-
background-image: -o-linear-gradient(top, #444444, #222222);
-
background-image: linear-gradient(to bottom, #444444, #222222);
-
background-repeat: repeat-x;
-
border-color: #222222 #222222 #000000;
-
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
-
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff444444', endColorstr='#ff222222', GradientType=0);
-
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
-
}
-
.btn-inverse:hover,
-
.btn-inverse:focus,
-
.btn-inverse:active,
-
.btn-inverse.active,
-
.btn-inverse.disabled,
-
.btn-inverse[disabled] {
-
color: #ffffff;
-
background-color: #222222;
-
*background-color: #151515;
-
}
-
.btn-inverse:active,
-
.btn-inverse.active {
-
background-color: #080808 \9;
-
}
-
button.btn,
-
input[type="submit"].btn {
-
*padding-top: 3px;
-
*padding-bottom: 3px;
-
}
-
button.btn::-moz-focus-inner,
-
input[type="submit"].btn::-moz-focus-inner {
-
padding: 0;
-
border: 0;
-
}
-
button.btn.btn-large,
-
input[type="submit"].btn.btn-large {
-
*padding-top: 7px;
-
*padding-bottom: 7px;
-
}
-
button.btn.btn-small,
-
input[type="submit"].btn.btn-small {
-
*padding-top: 3px;
-
*padding-bottom: 3px;
-
}
-
button.btn.btn-mini,
-
input[type="submit"].btn.btn-mini {
-
*padding-top: 1px;
-
*padding-bottom: 1px;
-
}
-
input[type="text"],
-
input[type="password"]{
-
display: inline-block;
-
height: 20px;
-
padding: 4px 6px;
-
margin-bottom: 10px;
-
font-size: 14px;
-
line-height: 20px;
-
color: #555555;
-
vertical-align: middle;
-
-webkit-border-radius: 4px;
-
-moz-border-radius: 4px;
-
border-radius: 4px;
-
}
-
input[type="text"],
-
input[type="password"]{
-
background-color: #ffffff;
-
border: 1px solid #cccccc;
-
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
-
-webkit-transition: border linear 0.2s, box-shadow linear 0.2s;
-
-moz-transition: border linear 0.2s, box-shadow linear 0.2s;
-
-o-transition: border linear 0.2s, box-shadow linear 0.2s;
-
transition: border linear 0.2s, box-shadow linear 0.2s;
-
}
-
input[type="text"]:focus,
-
input[type="password"]:focus{
-
border-color: rgba(82, 168, 236, 0.8);
-
outline: 0;
-
outline: thin dotted \9;
-
/* IE6-9 */
-
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
-moz-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(82, 168, 236, 0.6);
-
}
-
.fullwidth{
-
width:100%;
-
}
-
</style>
-
<script>
-
function Login()
-
{
-
var usrnm = document.getElementById("usrnm").value;
-
var pwd = document.getElementById("pwd").value;
-
-
if(usrnm != "" && pwd != "")
-
{
-
document.getElementById("demo").innerHTML = "Hello " + usrnm + "! How are you today? <br> Your password is "+pwd;
-
closemodal();//close the login modal
-
}
-
}
-
function showmodal(){
-
document.getElementById("loginBG").style.display="block";
-
}
-
function closemodal(){
-
document.getElementById("loginBG").style.display="none";
-
}
-
</script>
-
</head>
-
<body>
-
-
<p>Click the button to demonstrate the prompt box.</p>
-
<button onclick="showmodal()">Try it</button>
-
<div id="demo"></div>
-
-
<div id="loginBG" style="display:none;">
-
<div id="loginwrapper" class="loginwrapper">
-
<div align="right" style="float:right;margin-right:7px; margin-bottom:6px; margin-top:-2px;">
-
<button type="button" class="close" onclick="closemodal()" style="position:absolute;" title="Close">
-
<span aria-hidden="true">×</span>
-
</button>
-
</div>
-
<div style="clear:both; padding:0px;"></div>
-
<fieldset class="fieldset">
-
<legend>LOGIN</legend>
-
<form method="post" action="javascript:;">
-
<table>
-
<tr>
-
<td style="width:1%;">Username: </td>
-
<td>
-
<input type="text" id="usrnm" style="width:95%;">
-
</td>
-
</tr>
-
<tr>
-
<td>Password: </td>
-
<td>
-
<input type="password" id="pwd" style="width:95%;">
-
</td>
-
</tr>
-
</table>
-
<input type="submit" id="login" value="Login" class="btn btn-primary fullwidth" onClick="Login()">
-
</form>
-
</fieldset>
-
</div>
-
</div>
-
</body>
-
</html>
-
Sign in to post your reply or Sign up for a free account.
Similar topics
by: David |
last post by:
Hi,
I have a field from my recordset called RS("Password").
If I wish to display each character as an asterix '*' how do I go
about it.
I've seen the replace function, but cannot work out how...
|
by: ablyplus |
last post by:
Hi,
I am trying to open MS Access DB with c# like follows...
OleDbConnection thisConnection = new OleDbConnection(
@"Provider=Microsoft.Jet.OLEDB.4.0;" +
@"Data Source=" +
@"..\..\hren.mdb;"...
|
by: Benny Ng |
last post by:
Dear all,
The following is the source. The password is encrypted and saved into the
Binary in SQL2K.
Now I want to create a new page to compare the existed password and the
password that in the...
|
by: serkan |
last post by:
Guys,
I am trying to get this password reset functionality wor for me but I am not successful at all. Please somebody help me. I get "Your password could not be reset - please try again later" so I...
|
by: rhdyes |
last post by:
I work in a hospital and I am using php, postgres and apache to replace
old paradox databases. I have made a form that contains a dropdown
menu of the hospital units so I can choose the group of...
|
by: karen987 |
last post by:
I have an ASP news page to which you can add comments. The comments open up in a new window, and users can click reply to reply to them after which they are taken to the parent page which has a...
|
by: chaos |
last post by:
Hi all, i need help in this forgot password page, as the error message is show in another page cause the arrangement of the design in a mess. As i want to show the error message on the forgot...
|
by: George Lft |
last post by:
In my new registration page, i'm trying to create a double entry password / username to validate their entry . haven't decided which one, probably i'll go just with the password . What is the PHP...
|
by: whitey |
last post by:
Hi All,
The following script works when username(or email) and password are in 1 table. what i need to know is how to adjust the code to reflect that the email will be held in tbl_email and the...
|
by: calvinkwoo3000 |
last post by:
My Window application run property withour link to mdb without password.
Once i set security password to mdb file, the error belor come out when i click detail.
Not a valid password. and detail...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| | |