public
Fork of defunkt/facebox
Description: Facebook-style lightbox, built in jQuery
Homepage: http://famspam.com/facebox/
Clone URL: git://github.com/github/facebox.git
basic tweaks to the README
defunkt (author)
Tue Mar 11 22:09:12 -0700 2008
commit  e55ccdbcefe5c897946805c77dcfefe212f19d14
tree    c241049d2b271921ceff548193fb9bd330469eb2
parent  f4eee0a18e2c2f147b5d96c89969eef43ebc69a8
...
1
2
3
 
4
5
6
 
 
7
8
9
...
37
38
39
 
 
 
 
40
41
42
...
80
81
82
 
 
83
84
85
...
176
177
178
179
180
181
182
183
 
 
184
185
186
...
1
2
 
3
4
5
6
7
8
9
10
11
...
39
40
41
42
43
44
45
46
47
48
...
86
87
88
89
90
91
92
93
...
184
185
186
 
 
 
 
 
187
188
189
190
191
0
@@ -1,9 +1,11 @@
0
 /*
0
  * Facebox (for jQuery)
0
- * version: 1.1 (03/13/2008)
0
+ * version: 1.2 (03/13/2008)
0
  * @requires jQuery v1.2 or later
0
  *
0
  * Examples at http://famspam.com/facebox/
0
+ * Code at http://github.com/defunkt/facebox
0
+ * List at http://groups.google.com/groups/facebox
0
  *
0
  * Licensed under the MIT:
0
  * http://www.opensource.org/licenses/mit-license.php
0
@@ -37,6 +39,10 @@
0
  * This will show a loading screen before the passed function is called,
0
  * allowing for a better ajax experience.
0
  *
0
+ * Want to close the facebox? Trigger the 'close.facebox' document event:
0
+ *
0
+ * jQuery(document).trigger('close.facebox')
0
+ *
0
  */
0
 (function($) {
0
   $.facebox = function(data, klass) {
0
@@ -80,6 +86,8 @@
0
   </div>'
0
   }
0
 
0
+ // Opening the facebox adds #facebox to the url. Clicking 'back' closes the facebox
0
+ // but keeps you on the page you were on.
0
   function back_button_observer() {
0
     if (window.location.hash != $.facebox.settings.window_hash) $(document).trigger('close.facebox')
0
   }
0
@@ -176,11 +184,8 @@
0
   }
0
 
0
   $.facebox.init = function(settings) {
0
- if ($.facebox.settings.inited) {
0
- return true
0
- } else {
0
- $.facebox.settings.inited = true
0
- }
0
+ if ($.facebox.settings.inited) return true
0
+ else $.facebox.settings.inited = true
0
 
0
     if (settings) $.extend($.facebox.settings, settings)
0
     $('body').append($.facebox.settings.facebox_html)
...
4
5
6
7
 
8
9
10
...
55
56
57
58
 
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
...
226
227
228
229
 
230
231
232
...
4
5
6
 
7
8
9
10
...
55
56
57
 
58
59
60
61
62
63
 
 
 
 
 
 
 
 
 
64
65
66
...
217
218
219
 
220
221
222
223
0
@@ -4,7 +4,7 @@
0
 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
0
 <head>
0
   <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
0
- <title>Facebox 1.0</title>
0
+ <title>Facebox 1.2</title>
0
   <link href="facebox.css" media="screen" rel="stylesheet" type="text/css" />
0
   <link href="faceplant.css" media="screen" rel="stylesheet" type="text/css" />
0
   <script src="jquery.js" type="text/javascript"></script>
0
@@ -55,21 +55,12 @@
0
             in the tarball.
0
           </p>
0
           <p>
0
- <strong><a href="releases/facebox-1.0.tar.gz">Download Facebox v1.0</a></strong>
0
+ <strong><a href="releases/facebox-1.2.tar.gz">Download Facebox v1.2</a></strong>
0
           </p>
0
 
0
           <p>
0
             Want to live on the edge? The code is kept in <strong><a href="http://github.com">GitHub</a></strong> at <a href="http://github.com/defunkt/facebox">http://github.com/defunkt/facebox</a>
0
           </p>
0
- <!--
0
- <div class="code">
0
- <h3>Peruse the Code</h3>
0
- <ul>
0
- <li><a href="/facebox/facebox.js" class="code_link">facebox.js</a></li>
0
- <li><a href="/facebox/facebox.css" class="code_link">facebox.css</a></li>
0
- </ul>
0
- </div>
0
- -->
0
         </div>
0
 
0
 
0
@@ -226,7 +217,7 @@
0
       </p>
0
 
0
       <ul>
0
- <li> Code &copy;2007 Chris Wanstrath </li>
0
+ <li> Code &copy;2007/2008 Chris Wanstrath </li>
0
         <li> Style &copy;2007 Facebook </li>
0
         <li>MIT License</li>
0
       </ul>

Comments

    No one has commented yet.