How to dynamically set default tab via page anchor in URL
1. Add the following javascript as the first code in the tabberObj
function in tabber.js
if ( window.location.hash && window.location.hash.match( /^#/ ) )
{
var el =
document.getElementById(window.location.hash.substr(2));
if (el) {
el.className = "tabbertab tabbertabdefault"
}
}
2. Use by placing id on tab you wish to target:
<div id="screenshots" class="tabbertab">
3. Access via page anchor with underscore (underscore crucial
otherwise page will scroll in browser):
http://domain.com/path/to/page.html#_screenshots
We're using this on http://www.movabletype.com which should be
launched in the next 24 hours.
Enjoy!