-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
executable file
·32 lines (28 loc) · 1.17 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>LiteBox - base10Creations.com</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script>
<script src="assets/javascripts/LiteBox.js"></script>
<link rel="stylesheet" type="text/css" href="assets/stylesheets/LiteBox-required.css">
<!-- for demo -->
<link rel="stylesheet" type="text/css" href="assets/stylesheets/demo.css">
<script>
$(document).ready(function(){
var litebox = new LiteBox();
// Load Whatever you want; If it's got styles, it will use them.
// One "gotcha" is that it's not setup to grab image sizes before calculating and centering the overlay, so you need to specify the width/height of images.
$("#blah").click(function(){
// This could be an ajax return or whatever really.
// var content = '<img src="assets/images/sample.jpg" width="640" height="478">';
var content = '<div id="test"><h1>Test</h1><p>Some text</p></div>';
litebox.open(content);
});
});
</script>
</head>
<body>
<a href="#" id="blah">open litebox!</a>
</body>
</html>