[jQuery] Popup register form onclick?

Status
Not open for further replies.

Module

New Member
Jul 15, 2012
6
0
Okay, so I've been at it for a while now and I know it'll end up being simple in the end, but I haven't been having much luck.

I need it so when I user clicks 'Register' a box will fade-in which looks similar to this

Anyone able to help do this?
Cheers.
 

GarettM

Posting Freak
Aug 5, 2010
833
136
This is From a simple Vote script im making but u can convert it to your needs :3

HTML:
HTML:
<div id="pageblank" style="display: none"></div>
<!-- Register -->
<div id="Register" style="display: none">
<center>From here</center>
  
  <span id="close" style="font-size: 12px;text-align: right;float:right;">Cancle </span>
 
  <div class="box_sfoot"></div>
  </div>
</div>
<!-- Register -->
JAVASCRIPT:
HTML:
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.5.0/jquery.min.js"></script>
<script type="text/javascript">
  $(document).ready(function() {
        $("#openreg").click(function() {
            $("#Register").fadeIn("fast");
            $("#pageblank").fadeIn("fast");
        });
      $("#close").click(closeIt);
    });
 
    function closeIt() {
        $("#Register").fadeOut("fast");
        $("#pageblank").fadeOut("fast");
    }
</script>

CSS:
HTML:
#pageblank {
    width:10000px;
    height:100000px;
    position: absolute;
    top:0;
    left:0;
    background:black;
    opacity:0.4;
    filter:alpha(opacity=40); /* For IE8 and earlier */
    z-index:3;
}
#Register {
    width:300px;
    min-height: 300px;
    padding: 5px;
    position: absolute;
    top: 125px;
    right: 40%;
    display: block;
    z-index: 9999;
 
}

Hope i help at all :/
 
Status
Not open for further replies.

Users who are viewing this thread

Top