Skip to content
Browse files

Fixed IE8 "IE7 compatibility" mode regression, renamed jQuery.hashcha…

…nge* properties to jQuery.fn.hashchange.*, misc cleanup
  • Loading branch information...
1 parent f525dae commit 943e915546ed9dcab0d19e9de3a0ced938ca7f59 @cowboy committed Jul 21, 2010
View
6 README.markdown
@@ -1,7 +1,7 @@
# jQuery hashchange event #
[http://benalman.com/projects/jquery-hashchange-plugin/](http://benalman.com/projects/jquery-hashchange-plugin/)
-Version: 1.3pre, Last updated: 7/17/2010
+Version: 1.3pre, Last updated: 7/20/2010
This jQuery plugin enables very basic bookmarkable #hash history via a cross-browser window.onhashchange event.
@@ -28,7 +28,7 @@ reside (so you can test it yourself).
1.2.6, 1.3.2, 1.4.1, 1.4.2
### Browsers Tested ###
-Internet Explorer 6-8, Firefox 2-4, Chrome 3-5, Safari 3-5, Opera 9.6-10.60, iPhone 3.1, Android 2.1, BlackBerry 4.6-5.
+Internet Explorer 6-8, Firefox 2-4, Chrome 3-6, Safari 3-5, Opera 9.6-10.60, iPhone 3.1, Android 1.6-2.2, BlackBerry 4.6-5.
### Unit Tests ###
[http://benalman.com/code/projects/jquery-hashchange/unit/](http://benalman.com/code/projects/jquery-hashchange/unit/)
@@ -61,7 +61,7 @@ event, but not report that it does, the fallback polling loop will be used.
## Release History ##
-1.3pre - (7/17/2010) Reorganized IE6/7 Iframe code to make it more "removable" for mobile development. Added jQuery.hashchangeDomain, jQuery.hashchangeIframeSrc properties and document-domain.html file to address access denied issues when setting document.domain in IE6/7. Note that when using jQuery.hashchangeIframeSrc, history won't be recorded in IE6/7 until the Iframe src file loads. Lowered the default jQuery.hashchangeDelay to 50 milliseconds. Added IE6/7 document.title support. Attempt to make Iframe as hidden as possible by using techniques from http://www.paciellogroup.com/blog/?p=604. Added support for the "shortcut" format $(window).hashchange( fn ) and $(window).hashchange() like jQuery does for built-in events.
+1.3pre - (7/20/2010) Reorganized IE6/7 Iframe code to make it more "removable" for mobile-only development. Added IE6/7 document.title support. Attempted to make Iframe as hidden as possible by using techniques from http://www.paciellogroup.com/blog/?p=604. Added support for the "shortcut" format $(window).hashchange( fn ) and $(window).hashchange() like jQuery provides for built-in events. Renamed jQuery.hashchangeDelay to jQuery.fn.hashchange.delay and lowered its default value to 50. Added jQuery.fn.hashchange.domain and jQuery.fn.hashchange.src properties plus document-domain.html file to address access denied issues when setting document.domain in IE6/7.
1.2 - (2/11/2010) Fixed a bug where coming back to a page using this plugin from a page on another domain would cause an error in Safari 4. Also, IE6/7 Iframe is now inserted after the body (this actually works), which prevents the page from scrolling when the event is first bound. Event can also now be bound before DOM ready, but it won't be usable before then in IE6/7.
1.1 - (1/21/2010) Incorporated document.documentMode test to fix IE8 bug where browser version is incorrectly reported as 8.0, despite inclusion of the X-UA-Compatible IE=EmulateIE7 meta tag.
1.0 - (1/9/2010) Initial Release. Broke out the jQuery BBQ event.special window.onhashchange functionality into a separate plugin for users who want just the basic event & back button support, without all the extra awesomeness that BBQ provides. This plugin will be included as part of jQuery BBQ, but also be available separately.
View
22 docs/files/jquery-ba-hashchange-js.html
@@ -11,33 +11,33 @@
-<div id=Content><div class="CFile"><div class=CTopic id=MainTopic><h1 class=CTitle><a name="jQuery_hashchange_event"></a>jQuery hashchange event</h1><div class=CBody><p><b>Version: 1.3pre, Last updated: 7/17/2010</b></p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>Project Home</td><td class=CDLDescription><a href="http://benalman.com/projects/jquery-hashchange-plugin/" class=LURL target=_top>http://benalman.com<wbr>/projects<wbr>/jquery-hashchange-plugin<wbr>/</a></td></tr><tr><td class=CDLEntry>GitHub</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/" class=LURL target=_top>http://github.com/cowboy/jquery-hashchange/</a></td></tr><tr><td class=CDLEntry>Source</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.js" class=LURL target=_top>http://github.com<wbr>/cowboy<wbr>/jquery-hashchange<wbr>/raw<wbr>/master<wbr>/jquery.ba-hashchange.js</a></td></tr><tr><td class=CDLEntry>(Minified)</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.min.js" class=LURL target=_top>http://github.com<wbr>/cowboy<wbr>/jquery-hashchange<wbr>/raw<wbr>/master<wbr>/jquery.ba-hashchange.min.js</a> (0.8kb gzipped)</td></tr></table><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SMain"><td class=SEntry><a href="#jQuery_hashchange_event" >jQuery hashchange event</a></td><td class=SDescription><b>Version: 1.3pre, Last updated: 7/17/2010</b></td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#License" >License</a></td><td class=SDescription>Copyright &copy; 2010 &ldquo;Cowboy&rdquo; Ben Alman, Dual licensed under the MIT and GPL licenses. </td></tr><tr class="SGeneric"><td class=SEntry><a href="#Examples" >Examples</a></td><td class=SDescription>These working examples, complete with fully commented code, illustrate a few ways in which this plugin can be used.</td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#Support_and_Testing" >Support and Testing</a></td><td class=SDescription>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</td></tr><tr class="SGeneric"><td class=SEntry><a href="#Known_issues" >Known issues</a></td><td class=SDescription>While this jQuery hashchange event implementation is quite stable and robust, there are a few unfortunate browser bugs surrounding expected hashchange event-based behaviors, independent of any JavaScript window.onhashchange abstraction. </td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#Release_History" >Release History</a></td><td class=SDescription></td></tr><tr class="SGroup"><td class=SEntry><a href="#Properties" >Properties</a></td><td class=SDescription></td></tr><tr class="SProperty SIndent1 SMarked"><td class=SEntry><a href="#jQuery.hashchangeDelay" >jQuery.<wbr>hashchangeDelay</a></td><td class=SDescription>The numeric interval (in milliseconds) at which the <a href="#hashchange_event" class=LEvent id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')">hashchange event</a> polling loop executes. </td></tr><tr class="SProperty SIndent1"><td class=SEntry><a href="#jQuery.hashchangeDomain" >jQuery.<wbr>hashchangeDomain</a></td><td class=SDescription>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </td></tr><tr class="SProperty SIndent1 SMarked"><td class=SEntry><a href="#jQuery.hashchangeIframeSrc" >jQuery.<wbr>hashchangeIframeSrc</a></td><td class=SDescription>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in <a href="#jQuery.hashchangeDomain" class=LProperty id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')">jQuery.hashchangeDomain</a>), you can do so using this property. </td></tr><tr class="SGroup"><td class=SEntry><a href="#Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#jQuery.fn.hashchange" >jQuery.<wbr>fn.<wbr>hashchange</a></td><td class=SDescription>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </td></tr><tr class="SGroup"><td class=SEntry><a href="#Events" >Events</a></td><td class=SDescription></td></tr><tr class="SEvent SIndent1 SMarked"><td class=SEntry><a href="#hashchange_event" >hashchange event</a></td><td class=SDescription>Fired when location.hash changes. </td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
+<div id=Content><div class="CFile"><div class=CTopic id=MainTopic><h1 class=CTitle><a name="jQuery_hashchange_event"></a>jQuery hashchange event</h1><div class=CBody><p><b>Version: 1.3pre, Last updated: 7/20/2010</b></p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>Project Home</td><td class=CDLDescription><a href="http://benalman.com/projects/jquery-hashchange-plugin/" class=LURL target=_top>http://benalman.com<wbr>/projects<wbr>/jquery-hashchange-plugin<wbr>/</a></td></tr><tr><td class=CDLEntry>GitHub</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/" class=LURL target=_top>http://github.com/cowboy/jquery-hashchange/</a></td></tr><tr><td class=CDLEntry>Source</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.js" class=LURL target=_top>http://github.com<wbr>/cowboy<wbr>/jquery-hashchange<wbr>/raw<wbr>/master<wbr>/jquery.ba-hashchange.js</a></td></tr><tr><td class=CDLEntry>(Minified)</td><td class=CDLDescription><a href="http://github.com/cowboy/jquery-hashchange/raw/master/jquery.ba-hashchange.min.js" class=LURL target=_top>http://github.com<wbr>/cowboy<wbr>/jquery-hashchange<wbr>/raw<wbr>/master<wbr>/jquery.ba-hashchange.min.js</a> (0.8kb gzipped)</td></tr></table><!--START_ND_SUMMARY--><div class=Summary><div class=STitle>Summary</div><div class=SBorder><table border=0 cellspacing=0 cellpadding=0 class=STable><tr class="SMain"><td class=SEntry><a href="#jQuery_hashchange_event" >jQuery hashchange event</a></td><td class=SDescription><b>Version: 1.3pre, Last updated: 7/20/2010</b></td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#License" >License</a></td><td class=SDescription>Copyright &copy; 2010 &ldquo;Cowboy&rdquo; Ben Alman, Dual licensed under the MIT and GPL licenses. </td></tr><tr class="SGeneric"><td class=SEntry><a href="#Examples" >Examples</a></td><td class=SDescription>These working examples, complete with fully commented code, illustrate a few ways in which this plugin can be used.</td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#Support_and_Testing" >Support and Testing</a></td><td class=SDescription>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</td></tr><tr class="SGeneric"><td class=SEntry><a href="#Known_issues" >Known issues</a></td><td class=SDescription>While this jQuery hashchange event implementation is quite stable and robust, there are a few unfortunate browser bugs surrounding expected hashchange event-based behaviors, independent of any JavaScript window.onhashchange abstraction. </td></tr><tr class="SGeneric SMarked"><td class=SEntry><a href="#Release_History" >Release History</a></td><td class=SDescription></td></tr><tr class="SGroup"><td class=SEntry><a href="#Functions" >Functions</a></td><td class=SDescription></td></tr><tr class="SFunction SIndent1 SMarked"><td class=SEntry><a href="#jQuery.fn.hashchange" >jQuery.<wbr>fn.<wbr>hashchange</a></td><td class=SDescription>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </td></tr><tr class="SGroup"><td class=SEntry><a href="#Properties" >Properties</a></td><td class=SDescription></td></tr><tr class="SProperty SIndent1 SMarked"><td class=SEntry><a href="#jQuery.fn.hashchange.delay" >jQuery.<wbr>fn.<wbr>hashchange.<wbr>delay</a></td><td class=SDescription>The numeric interval (in milliseconds) at which the <a href="#hashchange_event" class=LEvent id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')">hashchange event</a> polling loop executes. </td></tr><tr class="SProperty SIndent1"><td class=SEntry><a href="#jQuery.fn.hashchange.domain" >jQuery.<wbr>fn.<wbr>hashchange.<wbr>domain</a></td><td class=SDescription>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </td></tr><tr class="SProperty SIndent1 SMarked"><td class=SEntry><a href="#jQuery.fn.hashchange.src" >jQuery.<wbr>fn.<wbr>hashchange.src</a></td><td class=SDescription>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in <a href="#jQuery.fn.hashchange.domain" class=LProperty id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')">jQuery.fn.hashchange.domain</a>), you can do so using this property. </td></tr><tr class="SGroup"><td class=SEntry><a href="#Events" >Events</a></td><td class=SDescription></td></tr><tr class="SEvent SIndent1 SMarked"><td class=SEntry><a href="#hashchange_event" >hashchange event</a></td><td class=SDescription>Fired when location.hash changes. </td></tr></table></div></div><!--END_ND_SUMMARY--></div></div></div>
<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="License"></a>License</h3><div class=CBody><p>Copyright &copy; 2010 &ldquo;Cowboy&rdquo; Ben Alman, Dual licensed under the MIT and GPL licenses.&nbsp; <a href="http://benalman.com/about/license/" class=LURL target=_top>http://benalman.com/about/license/</a></p></div></div></div>
<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Examples"></a>Examples</h3><div class=CBody><p>These working examples, complete with fully commented code, illustrate a few ways in which this plugin can be used.</p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>hashchange event</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/hashchange/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/hashchange<wbr>/</a></td></tr><tr><td class=CDLEntry>document.domain</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/document_domain/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/document_domain<wbr>/</a></td></tr></table></div></div></div>
-<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Support_and_Testing"></a>Support and Testing</h3><div class=CBody><p>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>jQuery Versions</td><td class=CDLDescription>1.2.6, 1.3.2, 1.4.1, 1.4.2</td></tr><tr><td class=CDLEntry>Browsers Tested</td><td class=CDLDescription>Internet Explorer 6-8, Firefox 2-4, Chrome 3-5, Safari 3-5, Opera 9.6-10.60, iPhone 3.1, Android 2.1, BlackBerry 4.6-5.</td></tr><tr><td class=CDLEntry>Unit Tests</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/unit/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/unit<wbr>/</a></td></tr></table></div></div></div>
+<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Support_and_Testing"></a>Support and Testing</h3><div class=CBody><p>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>jQuery Versions</td><td class=CDLDescription>1.2.6, 1.3.2, 1.4.1, 1.4.2</td></tr><tr><td class=CDLEntry>Browsers Tested</td><td class=CDLDescription>Internet Explorer 6-8, Firefox 2-4, Chrome 3-6, Safari 3-5, Opera 9.6-10.60, iPhone 3.1, Android 1.6-2.2, BlackBerry 4.6-5.</td></tr><tr><td class=CDLEntry>Unit Tests</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/unit/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/unit<wbr>/</a></td></tr></table></div></div></div>
<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Known_issues"></a>Known issues</h3><div class=CBody><p>While this jQuery hashchange event implementation is quite stable and robust, there are a few unfortunate browser bugs surrounding expected hashchange event-based behaviors, independent of any JavaScript window.onhashchange abstraction.&nbsp; See the following examples for more information:</p><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>Chrome: Back Button</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/bug-chrome-back-button/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/bug-chrome-back-button<wbr>/</a></td></tr><tr><td class=CDLEntry>Firefox: Remote XMLHttpRequest</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/bug-firefox-remote-xhr/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/bug-firefox-remote-xhr<wbr>/</a></td></tr><tr><td class=CDLEntry>WebKit: Back Button in an Iframe</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/bug-webkit-hash-iframe/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/bug-webkit-hash-iframe<wbr>/</a></td></tr><tr><td class=CDLEntry>Safari: Back Button from a different domain</td><td class=CDLDescription><a href="http://benalman.com/code/projects/jquery-hashchange/examples/bug-safari-back-from-diff-domain/" class=LURL target=_top>http://benalman.com<wbr>/code<wbr>/projects<wbr>/jquery-hashchange<wbr>/examples<wbr>/bug-safari-back-from-diff-domain<wbr>/</a></td></tr></table><p>Also note that should a browser natively support the window.onhashchange event, but not report that it does, the fallback polling loop will be used.</p></div></div></div>
-<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Release_History"></a>Release History</h3><div class=CBody><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>1.3pre</td><td class=CDLDescription>(7/17/2010) Reorganized IE6/7 Iframe code to make it more &ldquo;removable&rdquo; for mobile development.&nbsp; Added <a href="#jQuery.hashchangeDomain" class=LProperty id=link3 onMouseOver="ShowTip(event, 'tt2', 'link3')" onMouseOut="HideTip('tt2')">jQuery.hashchangeDomain</a>, <a href="#jQuery.hashchangeIframeSrc" class=LProperty id=link4 onMouseOver="ShowTip(event, 'tt3', 'link4')" onMouseOut="HideTip('tt3')">jQuery.hashchangeIframeSrc</a> properties and document-domain.html file to address access denied issues when setting document.domain in IE6/7.&nbsp; Note that when using <a href="#jQuery.hashchangeIframeSrc" class=LProperty id=link5 onMouseOver="ShowTip(event, 'tt3', 'link5')" onMouseOut="HideTip('tt3')">jQuery.hashchangeIframeSrc</a>, history won&rsquo;t be recorded in IE6/7 until the Iframe src file loads.&nbsp; Lowered the default <a href="#jQuery.hashchangeDelay" class=LProperty id=link6 onMouseOver="ShowTip(event, 'tt4', 'link6')" onMouseOut="HideTip('tt4')">jQuery.hashchangeDelay</a> to 50 milliseconds.&nbsp; Added IE6/7 document.title support.&nbsp; Attempt to make Iframe as hidden as possible by using techniques from <a href="http://www.paciellogroup.com/blog/?p=604" class=LURL target=_top>http://www.paciellogroup.com/blog/?p=604</a>.&nbsp; Added support for the &ldquo;shortcut&rdquo; format $(window).hashchange( fn ) and $(window).hashchange() like jQuery does for built-in events.</td></tr><tr><td class=CDLEntry>1.2</td><td class=CDLDescription>(2/11/2010) Fixed a bug where coming back to a page using this plugin from a page on another domain would cause an error in Safari 4.&nbsp; Also, IE6/7 Iframe is now inserted after the body (this actually works), which prevents the page from scrolling when the event is first bound.&nbsp; Event can also now be bound before DOM ready, but it won&rsquo;t be usable before then in IE6/7.</td></tr><tr><td class=CDLEntry>1.1</td><td class=CDLDescription>(1/21/2010) Incorporated document.documentMode test to fix IE8 bug where browser version is incorrectly reported as 8.0, despite inclusion of the X-UA-Compatible IE=EmulateIE7 meta tag.</td></tr><tr><td class=CDLEntry>1.0</td><td class=CDLDescription>(1/9/2010) Initial Release.&nbsp; Broke out the jQuery BBQ event.special window.onhashchange functionality into a separate plugin for users who want just the basic event &amp; back button support, without all the extra awesomeness that BBQ provides.&nbsp; This plugin will be included as part of jQuery BBQ, but also be available separately.</td></tr></table></div></div></div>
+<div class="CGeneric"><div class=CTopic><h3 class=CTitle><a name="Release_History"></a>Release History</h3><div class=CBody><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>1.3pre</td><td class=CDLDescription>(7/20/2010) Reorganized IE6/7 Iframe code to make it more &ldquo;removable&rdquo; for mobile-only development.&nbsp; Added IE6/7 document.title support.&nbsp; Attempted to make Iframe as hidden as possible by using techniques from <a href="http://www.paciellogroup.com/blog/?p=604" class=LURL target=_top>http://www.paciellogroup.com/blog/?p=604</a>.&nbsp; Added support for the &ldquo;shortcut&rdquo; format $(window).hashchange( fn ) and $(window).hashchange() like jQuery provides for built-in events.&nbsp; Renamed jQuery.hashchangeDelay to <a href="#jQuery.fn.hashchange.delay" class=LProperty id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')">jQuery.fn.hashchange.delay</a> and lowered its default value to 50.&nbsp; Added <a href="#jQuery.fn.hashchange.domain" class=LProperty id=link4 onMouseOver="ShowTip(event, 'tt2', 'link4')" onMouseOut="HideTip('tt2')">jQuery.fn.hashchange.domain</a> and <a href="#jQuery.fn.hashchange.src" class=LProperty id=link5 onMouseOver="ShowTip(event, 'tt4', 'link5')" onMouseOut="HideTip('tt4')">jQuery.fn.hashchange.src</a> properties plus document-domain.html file to address access denied issues when setting document.domain in IE6/7.</td></tr><tr><td class=CDLEntry>1.2</td><td class=CDLDescription>(2/11/2010) Fixed a bug where coming back to a page using this plugin from a page on another domain would cause an error in Safari 4.&nbsp; Also, IE6/7 Iframe is now inserted after the body (this actually works), which prevents the page from scrolling when the event is first bound.&nbsp; Event can also now be bound before DOM ready, but it won&rsquo;t be usable before then in IE6/7.</td></tr><tr><td class=CDLEntry>1.1</td><td class=CDLDescription>(1/21/2010) Incorporated document.documentMode test to fix IE8 bug where browser version is incorrectly reported as 8.0, despite inclusion of the X-UA-Compatible IE=EmulateIE7 meta tag.</td></tr><tr><td class=CDLEntry>1.0</td><td class=CDLDescription>(1/9/2010) Initial Release.&nbsp; Broke out the jQuery BBQ event.special window.onhashchange functionality into a separate plugin for users who want just the basic event &amp; back button support, without all the extra awesomeness that BBQ provides.&nbsp; This plugin will be included as part of jQuery BBQ, but also be available separately.</td></tr></table></div></div></div>
-<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Properties"></a>Properties</h3></div></div>
+<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Functions"></a>Functions</h3></div></div>
-<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.hashchangeDelay"></a>jQuery.<wbr>hashchangeDelay</h3><div class=CBody><p>The numeric interval (in milliseconds) at which the <a href="#hashchange_event" class=LEvent id=link7 onMouseOver="ShowTip(event, 'tt1', 'link7')" onMouseOut="HideTip('tt1')">hashchange event</a> polling loop executes.&nbsp; Defaults to 50.</p></div></div></div>
+<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="jQuery.fn.hashchange"></a>jQuery.<wbr>fn.<wbr>hashchange</h3><div class=CBody><p>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers.&nbsp; This behavior is consistent with jQuery&rsquo;s built-in event handlers.</p><h4 class=CHeading>Usage</h4><blockquote><pre>jQuery(window).hashchange( [ handler ] );</pre></blockquote><h4 class=CHeading>Arguments</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handler</td><td class=CDLDescription>(Function) Optional handler to be bound to the hashchange event.&nbsp; This is a &ldquo;shortcut&rdquo; for the more verbose form: jQuery(window).bind( &lsquo;hashchange&rsquo;, handler ).&nbsp; If handler is omitted, all bound window.onhashchange event handlers will be triggered.&nbsp; This is a shortcut for the more verbose jQuery(window).trigger( &lsquo;hashchange&rsquo; ).&nbsp; These forms are described in the <a href="#hashchange_event" class=LEvent id=link6 onMouseOver="ShowTip(event, 'tt1', 'link6')" onMouseOut="HideTip('tt1')">hashchange event</a> section.</td></tr></table><h4 class=CHeading>Returns</h4><p>(jQuery) The initial jQuery collection of elements.</p></div></div></div>
-<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.hashchangeDomain"></a>jQuery.<wbr>hashchangeDomain</h3><div class=CBody><p>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page.&nbsp; This property is only applicable to IE6/7.</p><p>In addition, the <a href="#jQuery.hashchangeIframeSrc" class=LProperty id=link8 onMouseOver="ShowTip(event, 'tt3', 'link8')" onMouseOut="HideTip('tt3')">jQuery.hashchangeIframeSrc</a> property must be set to the path of the included &ldquo;document-domain.html&rdquo; file, which can be renamed or modified if necessary (note that the document.domain specified must be the same in both your main JavaScript as well as in this file).</p><h4 class=CHeading>Usage</h4><p>jQuery.hashchangeDomain = document.domain;</p></div></div></div>
+<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Properties"></a>Properties</h3></div></div>
-<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.hashchangeIframeSrc"></a>jQuery.<wbr>hashchangeIframeSrc</h3><div class=CBody><p>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in <a href="#jQuery.hashchangeDomain" class=LProperty id=link9 onMouseOver="ShowTip(event, 'tt2', 'link9')" onMouseOut="HideTip('tt2')">jQuery.hashchangeDomain</a>), you can do so using this property.&nbsp; This property is only applicable to IE6/7.</p><h4 class=CHeading>Usage</h4><p>jQuery.hashchangeIframeSrc = &lsquo;path/to/file.html&rsquo;;</p></div></div></div>
+<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.fn.hashchange.delay"></a>jQuery.<wbr>fn.<wbr>hashchange.<wbr>delay</h3><div class=CBody><p>The numeric interval (in milliseconds) at which the <a href="#hashchange_event" class=LEvent id=link7 onMouseOver="ShowTip(event, 'tt1', 'link7')" onMouseOut="HideTip('tt1')">hashchange event</a> polling loop executes.&nbsp; Defaults to 50.</p></div></div></div>
-<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Functions"></a>Functions</h3></div></div>
+<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.fn.hashchange.domain"></a>jQuery.<wbr>fn.<wbr>hashchange.<wbr>domain</h3><div class=CBody><p>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page.&nbsp; This property is only applicable if you are supporting IE6/7 (or IE8 operating in &ldquo;IE7 compatibility&rdquo; mode).</p><p>In addition, the <a href="#jQuery.fn.hashchange.src" class=LProperty id=link8 onMouseOver="ShowTip(event, 'tt4', 'link8')" onMouseOut="HideTip('tt4')">jQuery.fn.hashchange.src</a> property must be set to the path of the included &ldquo;document-domain.html&rdquo; file, which can be renamed or modified if necessary (note that the document.domain specified must be the same in both your main JavaScript as well as in this file).</p><h4 class=CHeading>Usage</h4><p>jQuery.fn.hashchange.domain = document.domain;</p></div></div></div>
-<div class="CFunction"><div class=CTopic><h3 class=CTitle><a name="jQuery.fn.hashchange"></a>jQuery.<wbr>fn.<wbr>hashchange</h3><div class=CBody><p>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers.&nbsp; This behavior is consistent with jQuery&rsquo;s built-in event handlers.</p><h4 class=CHeading>Usage</h4><blockquote><pre>jQuery(window).hashchange( [ handler ] );</pre></blockquote><h4 class=CHeading>Arguments</h4><table border=0 cellspacing=0 cellpadding=0 class=CDescriptionList><tr><td class=CDLEntry>handler</td><td class=CDLDescription>(Function) Optional handler to be bound to the hashchange event.&nbsp; This is a &ldquo;shortcut&rdquo; for the more verbose form: jQuery(window).bind( &lsquo;hashchange&rsquo;, handler ).&nbsp; If handler is omitted, all bound window.onhashchange event handlers will be triggered.&nbsp; This is a shortcut for the more verbose jQuery(window).trigger( &lsquo;hashchange&rsquo; ).&nbsp; These forms are described in the <a href="#hashchange_event" class=LEvent id=link10 onMouseOver="ShowTip(event, 'tt1', 'link10')" onMouseOut="HideTip('tt1')">hashchange event</a> section.</td></tr></table><h4 class=CHeading>Returns</h4><p>(jQuery) The initial jQuery collection of elements.</p></div></div></div>
+<div class="CProperty"><div class=CTopic><h3 class=CTitle><a name="jQuery.fn.hashchange.src"></a>jQuery.<wbr>fn.<wbr>hashchange.src</h3><div class=CBody><p>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in <a href="#jQuery.fn.hashchange.domain" class=LProperty id=link9 onMouseOver="ShowTip(event, 'tt2', 'link9')" onMouseOut="HideTip('tt2')">jQuery.fn.hashchange.domain</a>), you can do so using this property.&nbsp; Note that when using this property, history won&rsquo;t be recorded in IE6/7 until the Iframe src file loads.&nbsp; This property is only applicable if you are supporting IE6/7 (or IE8 operating in &ldquo;IE7 compatibility&rdquo; mode).</p><h4 class=CHeading>Usage</h4><p>jQuery.fn.hashchange.src = &lsquo;path/to/file.html&rsquo;;</p></div></div></div>
<div class="CGroup"><div class=CTopic><h3 class=CTitle><a name="Events"></a>Events</h3></div></div>
-<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="hashchange_event"></a>hashchange event</h3><div class=CBody><p>Fired when location.hash changes.&nbsp; In browsers that support it, the native HTML5 window.onhashchange event is used, otherwise a polling loop is initialized, running every <a href="#jQuery.hashchangeDelay" class=LProperty id=link11 onMouseOver="ShowTip(event, 'tt4', 'link11')" onMouseOut="HideTip('tt4')">jQuery.hashchangeDelay</a> milliseconds to see if the hash has changed.&nbsp; In IE 6 and 7, a hidden Iframe is created to allow the back button and hash-based history to work.</p><h4 class=CHeading>Usage as described in <a href="#jQuery.fn.hashchange" class=LFunction id=link12 onMouseOver="ShowTip(event, 'tt5', 'link12')" onMouseOut="HideTip('tt5')">jQuery.fn.hashchange</a></h4><blockquote><pre>// Bind an event handler.
+<div class="CEvent"><div class=CTopic><h3 class=CTitle><a name="hashchange_event"></a>hashchange event</h3><div class=CBody><p>Fired when location.hash changes.&nbsp; In browsers that support it, the native HTML5 window.onhashchange event is used, otherwise a polling loop is initialized, running every <a href="#jQuery.fn.hashchange.delay" class=LProperty id=link10 onMouseOver="ShowTip(event, 'tt3', 'link10')" onMouseOut="HideTip('tt3')">jQuery.fn.hashchange.delay</a> milliseconds to see if the hash has changed.&nbsp; In IE6/7 (and IE8 operating in &ldquo;IE7 compatibility&rdquo; mode), a hidden Iframe is created to allow the back button and hash-based history to work.</p><h4 class=CHeading>Usage as described in <a href="#jQuery.fn.hashchange" class=LFunction id=link11 onMouseOver="ShowTip(event, 'tt5', 'link11')" onMouseOut="HideTip('tt5')">jQuery.fn.hashchange</a></h4><blockquote><pre>// Bind an event handler.
jQuery(window).hashchange( function(e) {
var hash = location.hash;
...
@@ -66,7 +66,7 @@
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt1"><div class=CEvent>Fired when location.hash changes. </div></div><div class=CToolTip id="tt2"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><div class=CToolTip id="tt3"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.hashchangeDomain), you can do so using this property. </div></div><div class=CToolTip id="tt4"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt5"><div class=CFunction>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt1"><div class=CEvent>Fired when location.hash changes. </div></div><div class=CToolTip id="tt2"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><div class=CToolTip id="tt3"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt4"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.fn.hashchange.domain), you can do so using this property. </div></div><div class=CToolTip id="tt5"><div class=CFunction>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </div></div><!--END_ND_TOOLTIPS-->
View
2 docs/index/Files.html
@@ -13,7 +13,7 @@
<div id=Index><div class=IPageTitle>File Index</div><div class=INavigationBar>$#! &middot; 0-9 &middot; A &middot; B &middot; C &middot; D &middot; E &middot; F &middot; G &middot; H &middot; I &middot; <a href="#J">J</a> &middot; K &middot; L &middot; M &middot; N &middot; O &middot; P &middot; Q &middot; R &middot; S &middot; T &middot; U &middot; V &middot; W &middot; X &middot; Y &middot; Z</div><table border=0 cellspacing=0 cellpadding=0><tr><td class=IHeading id=IFirstHeading><a name="J"></a>J</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery_hashchange_event" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')" class=ISymbol>jQuery hashchange event</a></td></tr></table>
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt1"><div class=CFile><b>Version: 1.3pre, Last updated: 7/17/2010</b></div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt1"><div class=CFile><b>Version: 1.3pre, Last updated: 7/20/2010</b></div></div><!--END_ND_TOOLTIPS-->
</div><!--Index-->
View
18 docs/index/General.html
@@ -11,29 +11,33 @@
-<div id=Index><div class=IPageTitle>Index</div><div class=INavigationBar>$#! &middot; 0-9 &middot; A &middot; B &middot; C &middot; D &middot; <a href="#E">E</a> &middot; <a href="#F">F</a> &middot; G &middot; <a href="#H">H</a> &middot; I &middot; <a href="#J">J</a> &middot; <a href="#K">K</a> &middot; <a href="#L">L</a> &middot; M &middot; N &middot; O &middot; <a href="#P">P</a> &middot; Q &middot; <a href="#R">R</a> &middot; <a href="#S">S</a> &middot; T &middot; U &middot; V &middot; W &middot; X &middot; Y &middot; Z</div><table border=0 cellspacing=0 cellpadding=0><tr><td class=IHeading id=IFirstHeading><a name="E"></a>E</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Events" class=ISymbol>Events</a></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Examples" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')" class=ISymbol>Examples</a></td></tr><tr><td class=IHeading><a name="F"></a>F</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Functions" class=ISymbol>Functions</a></td></tr><tr><td class=IHeading><a name="H"></a>H</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')" class=ISymbol>hashchange</a>, <span class=IParent>jQuery.fn</span></td></tr><tr><td class=ISymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#hashchange_event" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')" class=ISymbol>hashchange event</a></td></tr><tr><td class=ISymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDelay" id=link4 onMouseOver="ShowTip(event, 'tt4', 'link4')" onMouseOut="HideTip('tt4')" class=ISymbol>hashchangeDelay</a>, <span class=IParent>jQuery</span></td></tr><tr><td class=ISymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDomain" id=link5 onMouseOver="ShowTip(event, 'tt5', 'link5')" onMouseOut="HideTip('tt5')" class=ISymbol>hashchangeDomain</a>, <span class=IParent>jQuery</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeIframeSrc" id=link6 onMouseOver="ShowTip(event, 'tt6', 'link6')" onMouseOut="HideTip('tt6')" class=ISymbol>hashchangeIframeSrc</a>, <span class=IParent>jQuery</span></td></tr><tr><td class=IHeading><a name="J"></a>J</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery_hashchange_event" id=link7 onMouseOver="ShowTip(event, 'tt7', 'link7')" onMouseOut="HideTip('tt7')" class=ISymbol>jQuery hashchange event</a></td></tr><tr><td class=IHeading><a name="K"></a>K</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Known_issues" id=link8 onMouseOver="ShowTip(event, 'tt8', 'link8')" onMouseOut="HideTip('tt8')" class=ISymbol>Known issues</a></td></tr><tr><td class=IHeading><a name="L"></a>L</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#License" id=link9 onMouseOver="ShowTip(event, 'tt9', 'link9')" onMouseOut="HideTip('tt9')" class=ISymbol>License</a></td></tr><tr><td class=IHeading><a name="P"></a>P</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Properties" class=ISymbol>Properties</a></td></tr><tr><td class=IHeading><a name="R"></a>R</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Release_History" class=ISymbol>Release History</a></td></tr><tr><td class=IHeading><a name="S"></a>S</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Support_and_Testing" id=link10 onMouseOver="ShowTip(event, 'tt10', 'link10')" onMouseOut="HideTip('tt10')" class=ISymbol>Support and Testing</a></td></tr></table>
+<div id=Index><div class=IPageTitle>Index</div><div class=INavigationBar>$#! &middot; 0-9 &middot; A &middot; B &middot; C &middot; <a href="#D">D</a> &middot; <a href="#E">E</a> &middot; <a href="#F">F</a> &middot; G &middot; <a href="#H">H</a> &middot; I &middot; <a href="#J">J</a> &middot; <a href="#K">K</a> &middot; <a href="#L">L</a> &middot; M &middot; N &middot; O &middot; <a href="#P">P</a> &middot; Q &middot; <a href="#R">R</a> &middot; <a href="#S">S</a> &middot; T &middot; U &middot; V &middot; W &middot; X &middot; Y &middot; Z</div><table border=0 cellspacing=0 cellpadding=0><tr><td class=IHeading id=IFirstHeading><a name="D"></a>D</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.delay" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')" class=ISymbol>delay</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.domain" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')" class=ISymbol>domain</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr><tr><td class=IHeading><a name="E"></a>E</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Events" class=ISymbol>Events</a></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Examples" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')" class=ISymbol>Examples</a></td></tr><tr><td class=IHeading><a name="F"></a>F</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Functions" class=ISymbol>Functions</a></td></tr><tr><td class=IHeading><a name="H"></a>H</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange" id=link4 onMouseOver="ShowTip(event, 'tt4', 'link4')" onMouseOut="HideTip('tt4')" class=ISymbol>hashchange</a>, <span class=IParent>jQuery.fn</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#hashchange_event" id=link5 onMouseOver="ShowTip(event, 'tt5', 'link5')" onMouseOut="HideTip('tt5')" class=ISymbol>hashchange event</a></td></tr><tr><td class=IHeading><a name="J"></a>J</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery_hashchange_event" id=link6 onMouseOver="ShowTip(event, 'tt6', 'link6')" onMouseOut="HideTip('tt6')" class=ISymbol>jQuery hashchange event</a></td></tr><tr><td class=IHeading><a name="K"></a>K</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Known_issues" id=link7 onMouseOver="ShowTip(event, 'tt7', 'link7')" onMouseOut="HideTip('tt7')" class=ISymbol>Known issues</a></td></tr><tr><td class=IHeading><a name="L"></a>L</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#License" id=link8 onMouseOver="ShowTip(event, 'tt8', 'link8')" onMouseOut="HideTip('tt8')" class=ISymbol>License</a></td></tr><tr><td class=IHeading><a name="P"></a>P</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Properties" class=ISymbol>Properties</a></td></tr><tr><td class=IHeading><a name="R"></a>R</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Release_History" class=ISymbol>Release History</a></td></tr><tr><td class=IHeading><a name="S"></a>S</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.src" id=link9 onMouseOver="ShowTip(event, 'tt9', 'link9')" onMouseOut="HideTip('tt9')" class=ISymbol>src</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Support_and_Testing" id=link10 onMouseOver="ShowTip(event, 'tt10', 'link10')" onMouseOut="HideTip('tt10')" class=ISymbol>Support and Testing</a></td></tr></table>
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt1"><div class=CGeneric>These working examples, complete with fully commented code, illustrate a few ways in which this plugin can be used.</div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt1"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt2"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><!--END_ND_TOOLTIPS-->
+
+
+<!--START_ND_TOOLTIPS-->
+<div class=CToolTip id="tt3"><div class=CGeneric>These working examples, complete with fully commented code, illustrate a few ways in which this plugin can be used.</div></div><!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
<!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt2"><div class=CFunction>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </div></div><div class=CToolTip id="tt3"><div class=CEvent>Fired when location.hash changes. </div></div><div class=CToolTip id="tt4"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt5"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><div class=CToolTip id="tt6"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.hashchangeDomain), you can do so using this property. </div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt4"><div class=CFunction>Bind a handler to the window.onhashchange event or trigger all bound window.onhashchange event handlers. </div></div><div class=CToolTip id="tt5"><div class=CEvent>Fired when location.hash changes. </div></div><!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt7"><div class=CFile><b>Version: 1.3pre, Last updated: 7/17/2010</b></div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt6"><div class=CFile><b>Version: 1.3pre, Last updated: 7/20/2010</b></div></div><!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt8"><div class=CGeneric>While this jQuery hashchange event implementation is quite stable and robust, there are a few unfortunate browser bugs surrounding expected hashchange event-based behaviors, independent of any JavaScript window.onhashchange abstraction. </div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt7"><div class=CGeneric>While this jQuery hashchange event implementation is quite stable and robust, there are a few unfortunate browser bugs surrounding expected hashchange event-based behaviors, independent of any JavaScript window.onhashchange abstraction. </div></div><!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt9"><div class=CGeneric>Copyright &copy; 2010 &ldquo;Cowboy&rdquo; Ben Alman, Dual licensed under the MIT and GPL licenses. </div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt8"><div class=CGeneric>Copyright &copy; 2010 &ldquo;Cowboy&rdquo; Ben Alman, Dual licensed under the MIT and GPL licenses. </div></div><!--END_ND_TOOLTIPS-->
<!--START_ND_TOOLTIPS-->
@@ -45,7 +49,7 @@
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt10"><div class=CGeneric>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt9"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.fn.hashchange.domain), you can do so using this property. </div></div><div class=CToolTip id="tt10"><div class=CGeneric>Information about what version or versions of jQuery this plugin has been tested with, what browsers it has been tested in, and where the unit tests reside (so you can test it yourself).</div></div><!--END_ND_TOOLTIPS-->
</div><!--Index-->
View
8 docs/index/Properties.html
@@ -11,9 +11,13 @@
-<div id=Index><div class=IPageTitle>Property Index</div><div class=INavigationBar>$#! &middot; 0-9 &middot; A &middot; B &middot; C &middot; D &middot; E &middot; F &middot; G &middot; <a href="#H">H</a> &middot; I &middot; J &middot; K &middot; L &middot; M &middot; N &middot; O &middot; P &middot; Q &middot; R &middot; S &middot; T &middot; U &middot; V &middot; W &middot; X &middot; Y &middot; Z</div><table border=0 cellspacing=0 cellpadding=0><tr><td class=IHeading id=IFirstHeading><a name="H"></a>H</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDelay" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')" class=ISymbol>hashchangeDelay</a>, <span class=IParent>jQuery</span></td></tr><tr><td class=ISymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDomain" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')" class=ISymbol>hashchangeDomain</a>, <span class=IParent>jQuery</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeIframeSrc" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')" class=ISymbol>hashchangeIframeSrc</a>, <span class=IParent>jQuery</span></td></tr></table>
+<div id=Index><div class=IPageTitle>Property Index</div><div class=INavigationBar>$#! &middot; 0-9 &middot; A &middot; B &middot; C &middot; <a href="#D">D</a> &middot; E &middot; F &middot; G &middot; H &middot; I &middot; J &middot; K &middot; L &middot; M &middot; N &middot; O &middot; P &middot; Q &middot; R &middot; <a href="#S">S</a> &middot; T &middot; U &middot; V &middot; W &middot; X &middot; Y &middot; Z</div><table border=0 cellspacing=0 cellpadding=0><tr><td class=IHeading id=IFirstHeading><a name="D"></a>D</td><td></td></tr><tr><td class=ISymbolPrefix id=IFirstSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.delay" id=link1 onMouseOver="ShowTip(event, 'tt1', 'link1')" onMouseOut="HideTip('tt1')" class=ISymbol>delay</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr><tr><td class=ISymbolPrefix id=ILastSymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.domain" id=link2 onMouseOver="ShowTip(event, 'tt2', 'link2')" onMouseOut="HideTip('tt2')" class=ISymbol>domain</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr><tr><td class=IHeading><a name="S"></a>S</td><td></td></tr><tr><td class=ISymbolPrefix id=IOnlySymbolPrefix>&nbsp;</td><td class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.src" id=link3 onMouseOver="ShowTip(event, 'tt3', 'link3')" onMouseOut="HideTip('tt3')" class=ISymbol>src</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></td></tr></table>
<!--START_ND_TOOLTIPS-->
-<div class=CToolTip id="tt1"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt2"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><div class=CToolTip id="tt3"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.hashchangeDomain), you can do so using this property. </div></div><!--END_ND_TOOLTIPS-->
+<div class=CToolTip id="tt1"><div class=CProperty>The numeric interval (in milliseconds) at which the hashchange event polling loop executes. </div></div><div class=CToolTip id="tt2"><div class=CProperty>If you&rsquo;re setting document.domain in your JavaScript, and you want hash history to work in IE6/7, not only must this property be set, but you must also set document.domain BEFORE jQuery is loaded into the page. </div></div><!--END_ND_TOOLTIPS-->
+
+
+<!--START_ND_TOOLTIPS-->
+<div class=CToolTip id="tt3"><div class=CProperty>If, for some reason, you need to specify an Iframe src file (for example, when setting document.domain as in jQuery.fn.hashchange.domain), you can do so using this property. </div></div><!--END_ND_TOOLTIPS-->
</div><!--Index-->
View
6 docs/javascript/searchdata.js
@@ -125,11 +125,11 @@ var indexSectionsWithContent = {
"A": false,
"B": false,
"C": false,
- "D": false,
+ "D": true,
"E": false,
"F": false,
"G": false,
- "H": true,
+ "H": false,
"I": false,
"J": false,
"K": false,
@@ -140,7 +140,7 @@ var indexSectionsWithContent = {
"P": false,
"Q": false,
"R": false,
- "S": false,
+ "S": true,
"T": false,
"U": false,
"V": false,
View
BIN docs/nd/Data/ConfigFileInfo.nd
Binary file not shown.
View
4 docs/nd/Data/FileInfo.nd
@@ -1,4 +1,4 @@
1.4
JavaScript
-/srv/projects/jquery-hashchange/jquery.ba-hashchange.js 1279387585 1 jQuery hashchange event
-/srv/projects/jquery-hashchange/jquery.ba-hashchange.min.js 1279632848 0 /srv/projects/jquery-hashchange/jquery.ba-hashchange.min.js
+/srv/projects/jquery-hashchange-beta/jquery.ba-hashchange.min.js 1279680584 0 /srv/projects/jquery-hashchange-beta/jquery.ba-hashchange.min.js
+/srv/projects/jquery-hashchange-beta/jquery.ba-hashchange.js 1279680125 1 jQuery hashchange event
View
BIN docs/nd/Data/IndexInfo.nd
Binary file not shown.
View
BIN docs/nd/Data/PreviousMenuState.nd
Binary file not shown.
View
BIN docs/nd/Data/PreviousSettings.nd
Binary file not shown.
View
BIN docs/nd/Data/SymbolTable.nd
Binary file not shown.
View
2 docs/search/PropertiesH.html → docs/search/GeneralD.html
@@ -11,7 +11,7 @@
-<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_hashchangeDelay><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDelay" target=_parent class=ISymbol>hashchangeDelay</a>, <span class=IParent>jQuery</span></div></div><div class=SRResult id=SR_hashchangeDomain><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDomain" target=_parent class=ISymbol>hashchangeDomain</a>, <span class=IParent>jQuery</span></div></div><div class=SRResult id=SR_hashchangeIframeSrc><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeIframeSrc" target=_parent class=ISymbol>hashchangeIframeSrc</a>, <span class=IParent>jQuery</span></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
+<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_delay><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.delay" target=_parent class=ISymbol>delay</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div><div class=SRResult id=SR_domain><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.domain" target=_parent class=ISymbol>domain</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
document.getElementById("Loading").style.display="none";
document.getElementById("NoMatches").style.display="none";
var searchResults = new SearchResults("searchResults", "HTML");
View
2 docs/search/GeneralH.html
@@ -11,7 +11,7 @@
-<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_hashchange><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange" target=_parent class=ISymbol>hashchange</a>, <span class=IParent>jQuery.fn</span></div></div><div class=SRResult id=SR_hashchange_spcevent><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#hashchange_event" target=_parent class=ISymbol>hashchange event</a></div></div><div class=SRResult id=SR_hashchangeDelay><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDelay" target=_parent class=ISymbol>hashchangeDelay</a>, <span class=IParent>jQuery</span></div></div><div class=SRResult id=SR_hashchangeDomain><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeDomain" target=_parent class=ISymbol>hashchangeDomain</a>, <span class=IParent>jQuery</span></div></div><div class=SRResult id=SR_hashchangeIframeSrc><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.hashchangeIframeSrc" target=_parent class=ISymbol>hashchangeIframeSrc</a>, <span class=IParent>jQuery</span></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
+<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_hashchange><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange" target=_parent class=ISymbol>hashchange</a>, <span class=IParent>jQuery.fn</span></div></div><div class=SRResult id=SR_hashchange_spcevent><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#hashchange_event" target=_parent class=ISymbol>hashchange event</a></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
document.getElementById("Loading").style.display="none";
document.getElementById("NoMatches").style.display="none";
var searchResults = new SearchResults("searchResults", "HTML");
View
2 docs/search/GeneralS.html
@@ -11,7 +11,7 @@
-<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_Support_spcand_spcTesting><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Support_and_Testing" target=_parent class=ISymbol>Support and Testing</a></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
+<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_src><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.src" target=_parent class=ISymbol>src</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div><div class=SRResult id=SR_Support_spcand_spcTesting><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#Support_and_Testing" target=_parent class=ISymbol>Support and Testing</a></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
document.getElementById("Loading").style.display="none";
document.getElementById("NoMatches").style.display="none";
var searchResults = new SearchResults("searchResults", "HTML");
View
20 docs/search/PropertiesD.html
@@ -0,0 +1,20 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+
+<html><head><link rel="stylesheet" type="text/css" href="../styles/main.css"><script language=JavaScript src="../javascript/main.js"></script></head><body class="PopupSearchResultsPage" onLoad="NDOnLoad()"><script language=JavaScript><!--
+if (browserType) {document.write("<div class=" + browserType + ">");if (browserVer) {document.write("<div class=" + browserVer + ">"); }}// --></script>
+
+<!-- Generated by Natural Docs, version 1.4 -->
+<!-- http://www.naturaldocs.org -->
+
+<!-- saved from url=(0026)http://www.naturaldocs.org -->
+
+
+
+
+<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_delay><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.delay" target=_parent class=ISymbol>delay</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div><div class=SRResult id=SR_domain><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.domain" target=_parent class=ISymbol>domain</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
+document.getElementById("Loading").style.display="none";
+document.getElementById("NoMatches").style.display="none";
+var searchResults = new SearchResults("searchResults", "HTML");
+searchResults.Search();
+--></script></div><script language=JavaScript><!--
+if (browserType) {if (browserVer) {document.write("</div>"); }document.write("</div>");}// --></script></body></html>
View
20 docs/search/PropertiesS.html
@@ -0,0 +1,20 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
+
+<html><head><link rel="stylesheet" type="text/css" href="../styles/main.css"><script language=JavaScript src="../javascript/main.js"></script></head><body class="PopupSearchResultsPage" onLoad="NDOnLoad()"><script language=JavaScript><!--
+if (browserType) {document.write("<div class=" + browserType + ">");if (browserVer) {document.write("<div class=" + browserVer + ">"); }}// --></script>
+
+<!-- Generated by Natural Docs, version 1.4 -->
+<!-- http://www.naturaldocs.org -->
+
+<!-- saved from url=(0026)http://www.naturaldocs.org -->
+
+
+
+
+<div id=Index><div class=SRStatus id=Loading>Loading...</div><table border=0 cellspacing=0 cellpadding=0><div class=SRResult id=SR_src><div class=IEntry><a href="../files/jquery-ba-hashchange-js.html#jQuery.fn.hashchange.src" target=_parent class=ISymbol>src</a>, <span class=IParent>jQuery.<wbr>fn.<wbr>hashchange</span></div></div></table><div class=SRStatus id=Searching>Searching...</div><div class=SRStatus id=NoMatches>No Matches</div><script type="text/javascript"><!--
+document.getElementById("Loading").style.display="none";
+document.getElementById("NoMatches").style.display="none";
+var searchResults = new SearchResults("searchResults", "HTML");
+searchResults.Search();
+--></script></div><script language=JavaScript><!--
+if (browserType) {if (browserVer) {document.write("</div>"); }document.write("</div>");}// --></script></body></html>
View
4 examples/document_domain/index.php
@@ -17,8 +17,8 @@
// These two properties, set after jQuery and the hashchange event plugin are
// loaded, only need to be used when document.domain is set (to fix the "access
// denied" error in IE6/7).
- $.hashchangeIframeSrc = '../../document-domain.html';
- $.hashchangeDomain = document.domain;
+ $.fn.hashchange.src = '../../document-domain.html';
+ $.fn.hashchange.domain = document.domain;
// Bind an event to window.onhashchange that, when the hash changes, gets the
// hash and adds the class "selected" to any matching nav link.
View
142 jquery.ba-hashchange.js
@@ -1,5 +1,5 @@
/*!
- * jQuery hashchange event - v1.3pre - 7/17/2010
+ * jQuery hashchange event - v1.3pre - 7/20/2010
* http://benalman.com/projects/jquery-hashchange-plugin/
*
* Copyright (c) 2010 "Cowboy" Ben Alman
@@ -9,7 +9,7 @@
// Script: jQuery hashchange event
//
-// *Version: 1.3pre, Last updated: 7/17/2010*
+// *Version: 1.3pre, Last updated: 7/20/2010*
//
// Project Home - http://benalman.com/projects/jquery-hashchange-plugin/
// GitHub - http://github.com/cowboy/jquery-hashchange/
@@ -37,8 +37,8 @@
// reside (so you can test it yourself).
//
// jQuery Versions - 1.2.6, 1.3.2, 1.4.1, 1.4.2
-// Browsers Tested - Internet Explorer 6-8, Firefox 2-4, Chrome 3-5, Safari 3-5,
-// Opera 9.6-10.60, iPhone 3.1, Android 2.1, BlackBerry 4.6-5.
+// Browsers Tested - Internet Explorer 6-8, Firefox 2-4, Chrome 3-6, Safari 3-5,
+// Opera 9.6-10.60, iPhone 3.1, Android 1.6-2.2, BlackBerry 4.6-5.
// Unit Tests - http://benalman.com/code/projects/jquery-hashchange/unit/
//
// About: Known issues
@@ -59,17 +59,17 @@
//
// About: Release History
//
-// 1.3pre - (7/17/2010) Reorganized IE6/7 Iframe code to make it more
-// "removable" for mobile development. Added <jQuery.hashchangeDomain>,
-// <jQuery.hashchangeIframeSrc> properties and document-domain.html
+// 1.3pre - (7/20/2010) Reorganized IE6/7 Iframe code to make it more
+// "removable" for mobile-only development. Added IE6/7 document.title
+// support. Attempted to make Iframe as hidden as possible by using
+// techniques from http://www.paciellogroup.com/blog/?p=604. Added
+// support for the "shortcut" format $(window).hashchange( fn ) and
+// $(window).hashchange() like jQuery provides for built-in events.
+// Renamed jQuery.hashchangeDelay to <jQuery.fn.hashchange.delay> and
+// lowered its default value to 50. Added <jQuery.fn.hashchange.domain>
+// and <jQuery.fn.hashchange.src> properties plus document-domain.html
// file to address access denied issues when setting document.domain in
-// IE6/7. Note that when using <jQuery.hashchangeIframeSrc>, history
-// won't be recorded in IE6/7 until the Iframe src file loads. Lowered
-// the default <jQuery.hashchangeDelay> to 50 milliseconds. Added IE6/7
-// document.title support. Attempt to make Iframe as hidden as possible
-// by using techniques from http://www.paciellogroup.com/blog/?p=604.
-// Added support for the "shortcut" format $(window).hashchange( fn )
-// and $(window).hashchange() like jQuery does for built-in events.
+// IE6/7.
// 1.2 - (2/11/2010) Fixed a bug where coming back to a page using this plugin
// from a page on another domain would cause an error in Safari 4. Also,
// IE6/7 Iframe is now inserted after the body (this actually works),
@@ -109,39 +109,6 @@
return '#' + url.replace( /^[^#]*#?(.*)$/, '$1' );
};
- // Property: jQuery.hashchangeDelay
- //
- // The numeric interval (in milliseconds) at which the <hashchange event>
- // polling loop executes. Defaults to 50.
-
- $[ str_hashchange + 'Delay' ] = 50;
-
- // Property: jQuery.hashchangeDomain
- //
- // If you're setting document.domain in your JavaScript, and you want hash
- // history to work in IE6/7, not only must this property be set, but you must
- // also set document.domain BEFORE jQuery is loaded into the page. This
- // property is only applicable to IE6/7.
- //
- // In addition, the <jQuery.hashchangeIframeSrc> property must be set to the
- // path of the included "document-domain.html" file, which can be renamed or
- // modified if necessary (note that the document.domain specified must be the
- // same in both your main JavaScript as well as in this file).
- //
- // Usage:
- //
- // jQuery.hashchangeDomain = document.domain;
-
- // Property: jQuery.hashchangeIframeSrc
- //
- // If, for some reason, you need to specify an Iframe src file (for example,
- // when setting document.domain as in <jQuery.hashchangeDomain>), you can do
- // so using this property. This property is only applicable to IE6/7.
- //
- // Usage:
- //
- // jQuery.hashchangeIframeSrc = 'path/to/file.html';
-
// Method: jQuery.fn.hashchange
//
// Bind a handler to the window.onhashchange event or trigger all bound
@@ -172,13 +139,55 @@
return fn ? this.bind( str_hashchange, fn ) : this.trigger( str_hashchange );
};
+ // Property: jQuery.fn.hashchange.delay
+ //
+ // The numeric interval (in milliseconds) at which the <hashchange event>
+ // polling loop executes. Defaults to 50.
+
+ // Property: jQuery.fn.hashchange.domain
+ //
+ // If you're setting document.domain in your JavaScript, and you want hash
+ // history to work in IE6/7, not only must this property be set, but you must
+ // also set document.domain BEFORE jQuery is loaded into the page. This
+ // property is only applicable if you are supporting IE6/7 (or IE8 operating
+ // in "IE7 compatibility" mode).
+ //
+ // In addition, the <jQuery.fn.hashchange.src> property must be set to the
+ // path of the included "document-domain.html" file, which can be renamed or
+ // modified if necessary (note that the document.domain specified must be the
+ // same in both your main JavaScript as well as in this file).
+ //
+ // Usage:
+ //
+ // jQuery.fn.hashchange.domain = document.domain;
+
+ // Property: jQuery.fn.hashchange.src
+ //
+ // If, for some reason, you need to specify an Iframe src file (for example,
+ // when setting document.domain as in <jQuery.fn.hashchange.domain>), you can
+ // do so using this property. Note that when using this property, history
+ // won't be recorded in IE6/7 until the Iframe src file loads. This property
+ // is only applicable if you are supporting IE6/7 (or IE8 operating in "IE7
+ // compatibility" mode).
+ //
+ // Usage:
+ //
+ // jQuery.fn.hashchange.src = 'path/to/file.html';
+
+ $.fn[ str_hashchange ].delay = 50;
+ /*
+ $.fn[ str_hashchange ].domain = null;
+ $.fn[ str_hashchange ].src = null;
+ */
+
// Event: hashchange event
//
// Fired when location.hash changes. In browsers that support it, the native
// HTML5 window.onhashchange event is used, otherwise a polling loop is
- // initialized, running every <jQuery.hashchangeDelay> milliseconds to see if
- // the hash has changed. In IE 6 and 7, a hidden Iframe is created to allow
- // the back button and hash-based history to work.
+ // initialized, running every <jQuery.fn.hashchange.delay> milliseconds to
+ // see if the hash has changed. In IE6/7 (and IE8 operating in "IE7
+ // compatibility" mode), a hidden Iframe is created to allow the back button
+ // and hash-based history to work.
//
// Usage as described in <jQuery.fn.hashchange>:
//
@@ -266,8 +275,8 @@
timeout_id = undefined;
};
- // This polling loop checks every $.hashchangeDelay milliseconds to see if
- // location.hash has changed, and triggers the 'hashchange' event on
+ // This polling loop checks every $.fn.hashchange.delay milliseconds to see
+ // if location.hash has changed, and triggers the 'hashchange' event on
// window when necessary.
function poll() {
var hash = get_fragment(),
@@ -282,25 +291,24 @@
location.href = location.href.replace( /#.*/, '' ) + history_hash;
}
- timeout_id = setTimeout( poll, $[ str_hashchange + 'Delay' ] );
+ timeout_id = setTimeout( poll, $.fn[ str_hashchange ].delay );
};
- // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
- // vvvvvvvvvvvvvvvvvvv REMOVE IF NOT SUPPORTING IE6/7 vvvvvvvvvvvvvvvvvvv
- // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
- (function(){
- var browser = $.browser,
- iframe,
- iframe_src;
+ // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
+ // vvvvvvvvvvvvvvvvvvv REMOVE IF NOT SUPPORTING IE6/7/8 vvvvvvvvvvvvvvvvvvv
+ // vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
+ $.browser.msie && !supports_onhashchange && (function(){
+ // Not only do IE6/7 need the "magical" Iframe treatment, but so does IE8
+ // when running in "IE7 compatibility" mode.
- // If browser isn't IE 6/7, abort!! ABORT!!!
- if ( !browser.msie || browser.version > 7 ) { return; }
+ var iframe,
+ iframe_src;
// When the event is bound and polling starts in IE 6/7, create a hidden
// Iframe for history handling.
self.start = function(){
if ( !iframe ) {
- iframe_src = $[ str_hashchange + 'IframeSrc' ];
+ iframe_src = $.fn[ str_hashchange ].src;
iframe_src = iframe_src && iframe_src + get_fragment();
// Create hidden Iframe. Attempt to make Iframe as hidden as possible
@@ -351,7 +359,7 @@
// been set, update that as well.
history_set = function( hash, history_hash ) {
var iframe_doc = iframe.document,
- domain = $[ str_hashchange + 'Domain' ];
+ domain = $.fn[ str_hashchange ].domain;
if ( hash !== history_hash ) {
// Update Iframe with any initial `document.title` that might be set.
@@ -372,9 +380,9 @@
};
})();
- // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- // ^^^^^^^^^^^^^^^^^^^ REMOVE IF NOT SUPPORTING IE6/7 ^^^^^^^^^^^^^^^^^^^
- // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+ // ^^^^^^^^^^^^^^^^^^^ REMOVE IF NOT SUPPORTING IE6/7/8 ^^^^^^^^^^^^^^^^^^^
+ // ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
return self;
})();
View
4 jquery.ba-hashchange.min.js
@@ -1,9 +1,9 @@
/*
- * jQuery hashchange event - v1.3pre - 7/17/2010
+ * jQuery hashchange event - v1.3pre - 7/20/2010
* http://benalman.com/projects/jquery-hashchange-plugin/
*
* Copyright (c) 2010 "Cowboy" Ben Alman
* Dual licensed under the MIT and GPL licenses.
* http://benalman.com/about/license/
*/
-(function($,e,b){var c="hashchange",h=document,f,g=$.event.special,i=h.documentMode,d="on"+c in e&&(i===b||i>7);function a(j){j=j||location.href;return"#"+j.replace(/^[^#]*#?(.*)$/,"$1")}$[c+"Delay"]=50;$.fn[c]=function(j){return j?this.bind(c,j):this.trigger(c)};g[c]=$.extend(g[c],{setup:function(){if(d){return false}$(f.start)},teardown:function(){if(d){return false}$(f.stop)}});f=(function(){var j={},p,m=a(),k=function(q){return q},l=k,o=k;j.start=function(){p||n()};j.stop=function(){p&&clearTimeout(p);p=b};function n(){var r=a(),q=o(m);if(r!==m){l(m=r,q);$(e).trigger(c)}else{if(q!==m){location.href=location.href.replace(/#.*/,"")+q}}p=setTimeout(n,$[c+"Delay"])}(function(){var q=$.browser,r,s;if(!q.msie||q.version>7){return}j.start=function(){if(!r){s=$[c+"IframeSrc"];s=s&&s+a();r=$('<iframe tabindex="-1" title="empty"/>').hide().one("load",function(){s||l(a());n()}).attr("src",s||"javascript:0").insertAfter("body")[0].contentWindow;h.onpropertychange=function(){try{if(event.propertyName==="title"){r.document.title=h.title}}catch(t){}}}};j.stop=k;o=function(){return a(r.location.href)};l=function(w,t){var v=r.document,u=$[c+"Domain"];if(w!==t){v.title=h.title;v.open();u&&v.write('<script>document.domain="'+u+'"<\/script>');v.close();r.location.hash=w}}})();return j})()})(jQuery,this);
+(function($,e,b){var c="hashchange",h=document,f,g=$.event.special,i=h.documentMode,d="on"+c in e&&(i===b||i>7);function a(j){j=j||location.href;return"#"+j.replace(/^[^#]*#?(.*)$/,"$1")}$.fn[c]=function(j){return j?this.bind(c,j):this.trigger(c)};$.fn[c].delay=50;g[c]=$.extend(g[c],{setup:function(){if(d){return false}$(f.start)},teardown:function(){if(d){return false}$(f.stop)}});f=(function(){var j={},p,m=a(),k=function(q){return q},l=k,o=k;j.start=function(){p||n()};j.stop=function(){p&&clearTimeout(p);p=b};function n(){var r=a(),q=o(m);if(r!==m){l(m=r,q);$(e).trigger(c)}else{if(q!==m){location.href=location.href.replace(/#.*/,"")+q}}p=setTimeout(n,$.fn[c].delay)}$.browser.msie&&!d&&(function(){var q,r;j.start=function(){if(!q){r=$.fn[c].src;r=r&&r+a();q=$('<iframe tabindex="-1" title="empty"/>').hide().one("load",function(){r||l(a());n()}).attr("src",r||"javascript:0").insertAfter("body")[0].contentWindow;h.onpropertychange=function(){try{if(event.propertyName==="title"){q.document.title=h.title}}catch(s){}}}};j.stop=k;o=function(){return a(q.location.href)};l=function(v,s){var u=q.document,t=$.fn[c].domain;if(v!==s){u.title=h.title;u.open();t&&u.write('<script>document.domain="'+t+'"<\/script>');u.close();q.location.hash=v}}})();return j})()})(jQuery,this);
View
4 unit/unit.js
@@ -63,8 +63,8 @@ function get_fragment( url ) {
};
if ( window.document_domain_set ) {
- $.hashchangeIframeSrc = '../document-domain.html';
- $.hashchangeDomain = document.domain;
+ $.fn.hashchange.src = '../document-domain.html';
+ $.fn.hashchange.domain = document.domain;
}
// Event can be bound before DOM ready.

0 comments on commit 943e915

Please sign in to comment.
Something went wrong with that request. Please try again.