Execute
Save
Share
Share link
share
share
share
Team
Public Teams
Comments
0
Created By:
Guest
Title:
div popup with jquery
Title
Description
Edit
Copy Link
Login
Email *
Password *
Login
OR
Create Account
Screen Name *
Email *
Password *
Retype Password *
Team Access Code
Register
Public CodeBins
HELP
--Select Theme--
Ambiance
Blackboard
Cobalt
Eclipse
Elegant
Erlang-Dark
Lesser-Dark
Monokai
Neat
Night
Rubyblue
Vibrant-Ink
Xq-Dark
New CodeBin
CodeBins Versions
div popup with - V.75
div popup with - V.74
div popup with - V.73
div popup with - V.72
div popup with - V.71
div popup with - V.70
div popup with - V.69
div popup with - V.68
div popup with - V.67
div popup with - V.66
div popup with - V.65
div popup with - V.64
div popup with - V.63
div popup with - V.62
div popup with - V.61
div popup with - V.60
div popup with - V.59
div popup with - V.58
div popup with - V.57
div popup with - V.56
div popup with - V.55
div popup with - V.54
div popup with - V.53
div popup with - V.52
div popup with - V.51
div popup with - V.50
div popup with - V.49
div popup with - V.48
div popup with - V.47
div popup with - V.46
div popup with - V.45
div popup with - V.44
div popup with - V.43
div popup with - V.42
div popup with - V.41
div popup with - V.40
div popup with - V.39
div popup with - V.38
div popup with - V.37
div popup with - V.36
div popup with - V.35
div popup with - V.34
div popup with - V.33
div popup with - V.32
div popup with - V.31
div popup with - V.30
div popup with - V.29
div popup with - V.28
div popup with - V.27
div popup with - V.26
div popup with - V.25
div popup with - V.24
div popup with - V.23
div popup with - V.22
div popup with - V.21
div popup with - V.20
div popup with - V.19
div popup with - V.18
div popup with - V.17
div popup with - V.16
div popup with - V.15
div popup with - V.14
div popup with - V.13
div popup with - V.12
div popup with - V.11
div popup with - V.10
div popup with - V.9
div popup with - V.8
div popup with - V.7
div popup with - V.6
div popup with - V.5
div popup with - V.4
div popup with - V.3
div popup with - V.2
div popup with - V.1
Compare Versions
Recent CodeBins
View All CodeBins
$(function() { $(".item").click(function(e) { //Cancel the link behavior e.preventDefault(); //Get Dialog Object var $dialog = $("#dialog"); //Get the screen height and width var maskHeight = $(document).height(); var maskWidth = $(window).width(); //Set heigth and width to mask to fill up the whole screen //transition effect // $('#mask').fadeIn(1000); //$('#mask').fadeTo("slow", 0.8); //Get the window height and width var winH = $(window).height(); var winW = $(window).width(); //Set the popup window to center $dialog.css('top', winH / 2 - $dialog.height() / 2); $dialog.css('left', winW / 2 - $dialog.width() / 2); //Set Message var MSG = $(this).find(".postname").text().trim() + " " + $(this).find(".decs").text().trim(); $dialog.find("#msg").html(MSG); //transition effect $dialog.fadeIn(20); }); //if close button is clicked $('.window .close').click(function(e) { //Cancel the link behavior e.preventDefault(); $('#mask').hide(); $('.window').hide(); }); //if mask is clicked $('#mask').click(function() { $(this).hide(); $('.window').hide(); }); });
Bottom of Page
In Head
On Load
On Ready
Setting
Validate
Copy
Format
#mask{ position:absolute; left:0; top:0; z-index:9000; background-color:#000; opacity:0.5; display:none; } a{ color:#333; text-decoration:none } a:hover{ color:#ccc; text-decoration:none } #boxes #dialog{ padding:0px; width:675px; height:100px; padding:10px; bordercolor:1px solid #445cd88; background-color:#44bb55; display:none; position:absolute; z-index:99999; border-radius: 1.2em; -moz-box-shadow: 5px 5px 2px 2px #44fc65; -webkit-box-shadow: 5px 5px 2px 2px #44fc65; box-shadow: 5px 5px 2px 2px #44fc65; } #dialog #title{ background:#f8a233; bordercolor:1px solid #445cd88; border-radius: 1.5em; margin:0px; padding:5px; } #dialog #msg{ margin-left:20px; padding:5px; font-size:14px; } #dialog .close{ display:block; float:right; background:#afa1f5; bordercolor:1px solid #445cd88; border-radius: 1.2em; width:100px; text-align:center; font-size:13px; } #dialog .close:hover{ background:#af55d9; bordercolor:1px solid #445cd88; } .item { background:#0088CC; color:#fff; margin: 10px; border:1px solid #3355a9; border-radius: 1.2em; padding:10px; -moz-box-shadow: 5px 5px 2px 2px #999; -webkit-box-shadow: 5px 5px 2px 2px #999; box-shadow: 5px 5px 2px 2px #999; text-shadow:0 1px 1px #194B7E; }
Setting
Validate
Copy
Format
<div id="panel"> <div class="item"> <div id="popupnow" style="display:none;background-color:white;width:auto"> <span class="postname"> Orden 1 </span> <span class="decs" > Afiliado 1 </span> </div> <span class="postname"> Orden 1 </span> <span class="decs" > Afiliado 1 </span> </div> <div class="item"> <div id="popupnow" style="display:none;background-color:white;width:auto"> <span class="postname"> Orden 2 </span> <span class="decs" > Afiliado 2 </span> </div> <span class="postname"> Orden 2 </span> <span class="decs" > Afiliado 2 </span> </div> <div class="item"> <div id="popupnow" style="display:none;background-color:white;width:auto"> <span class="postname"> Orden 3 </span> <span class="decs" > Afiliado 3 </span> </div> <span class="postname"> Orden 3 </span> <span class="decs" > Afiliado 3 </span> </div> <div class="item"> <div id="popupnow" style="display:none;background-color:white;width:auto"> <span class="postname"> Orden 4 </span> <span class="decs" > Afiliado 4 </span> </div> <span class="postname"> Orden 4 </span> <span class="decs" > Afiliado 4 </span> </div> <div class="item"> <span class="postname"> Orden 5 </span> <span class="decs" > Afiliado 5 </span> </div> <!-- Dialog Box --> <div id="boxes"> <div id="dialog" class="window"> <div id="title"> Cabecera Orden </div> <div> <p> Practica 1 <br> Practica 2 <br> Practica 3 <br> Practica 4 <br> </p> </div> <a href="#"class="close"/> Cerrar </a> </div> </div> <!-- Mask to cover the whole screen --> <div id="mask"> </div>
No Doc Type
HTML5
HTML 4.01 Transitional
HTML 4.01 Strict
HTML 4.01 Frameset
XHTML 1.1
XHTML 1.0 Transitional
XHTML 1.0 Strict
XHTML 1.0 Frameset
Copy
Format
Download
×
Code Description
×
Difference of Versions
HTML
CSS
JS
×
JS Error
×
CSS Error
Errors
Warnings
×
JavaScript Setting
JS Libraries:
Chrome Frame 1.0.3
Dojo 1.8.0
Dojo 1.7.3
Dojo 1.7.2
Ext Core 3.1.0
jQuery 1.8.0
jQuery 1.7.2
jQuery 1.6.0
jQuery 1.5.0
jQuery 1.4.4
jQuery 1.4.0
jQuery-min 1.7.2
jQueryUI-min 1.8.21
MooTools more-1.4.0.1-full
MooTools core-1.4.5-full
MooTools core-1.4.1-full
Prototype 1.7.1.0
script.aculo.us 1.9.0
SWFObject 2.2
Twitter Bootstrap 2.0.4
WebFont Loader 1.0.28
yui 3.5.1
User Libraries:
Upload File
JavaScript URL(s):
×
CSS Setting
CSS Libraries:
jQueryUI 1.8.21
Twitter Bootstrap 2.0.4
User Libraries:
Upload File
CSS URL(s):