Powerful jquery plugin Jqeuryui do the web dialog box effect! Simple _jquery

Source: Internet
Author: User
Tags blank page

Let's start with the simplest, web login window;

But before we start, we'll download the jquery plugin.
I used to use the VS2008 to do the Web page, first add a blank page

This is the simplest way ... Insert inside the body first

<body>
<div id= "Div1" >
<table>
<tr><td> username </td><td><input type= "text" style= "width:100px"/></td></tr>
<tr><td> password </td><td><input type= "text" style= "width:100px"/></td></tr>
</table>
</div>
</body>

This is the time we need to unpack the downloaded things. Put the jquery1.4.2 folder in the Jquery-1.4.2.js and Jquery-ui-1.8.11.custom folder in the JS folder Jquery-ui-1.8.11.custom.min.js, the two copies to the directory

Now we have to add a reference, this time if it is installed 2008 SP1, you can drag the two JS files to the code head tag, of course, can also manually add, look at the picture:


We're going to use it next.

<script type= "Text/javascript" >
$ (function () {
$ ("#div1"). Dialog ();
});
</script>

The dialog () method of directly calling the object; Well ... Look at the effect.

Not very nice, right? Don't be nervous, at this time we copy the CSS folder in the Jquery-ui-1.8.11.custom folder in, look at the picture ...

Add a reference to this jquery-ui-1.8.11.custom.css,css file

All right... Look at the effect.

It's such a simple code ...

Copy Code code as follows:

<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd ">
xmlns= "http://www.w3.org/1999/xhtml" >
<title></title>
<link href= ". /css/ui-lightness/jquery-ui-1.8.11.custom.css "rel=" stylesheet "type=" Text/css "/>"
<script src= "Jquery-1.4.2.js" type= "Text/javascript" ></script>
<script src= "Jquery-ui-1.8.11.custom.min.js" type= "Text/javascript" ></script>
<script type= "Text/javascript" >
$ (function () {
$ ("#div1"). Dialog ();
});
</script>
<body>
<div id= "Div1" >
<table>
<tr><td> username </td><td><input type= "text" style= "width:100px"/></td></tr>
<tr><td> password </td><td><input type= "text" style= "width:100px"/></td></tr>
</table>
</div>
</body>

Everybody study ... Have a good also tell me oh ...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.