Team:TU Delft/test
From 2010.igem.org
(Difference between revisions)
Line 140: | Line 140: | ||
function moveToAnchor(anchor) { | function moveToAnchor(anchor) { | ||
- | var pos = $('# | + | try { |
- | + | var pos = $('#iGEM_TU_Delft_container > a[name='+anchor+']').offset(); | |
- | + | dbgout('anchor: '+anchor+'; pos=' + pos.left + ','+pos.top ); | |
+ | window.scroll(pos.left, pos.top); | ||
+ | } catch (err) { | ||
+ | dbgout('moveToAnchor error: ' + err); | ||
+ | } | ||
} | } | ||
Line 225: | Line 229: | ||
this.href = this.href.replace("https://2010.igem.org/Team:TU_Delft/", "#page="); | this.href = this.href.replace("https://2010.igem.org/Team:TU_Delft/", "#page="); | ||
- | + | // dbgout('rewriting ' + url + ' to ' + this.href); | |
}); | }); | ||
} | } |
Revision as of 20:50, 26 October 2010
![](https://static.igem.org/mediawiki/2010/d/d8/TUDelft_2010_AlkanivoreAnimated.gif)