Difference between revisions of "Template:Tuebingen"
Line 253: | Line 253: | ||
if (location.search.length != 0) { | if (location.search.length != 0) { | ||
− | diaslide = | + | diaslide = gup('slide',window.href); |
− | anchor | + | anchor = gup('anchor',window.href); |
console.log('ds '+diaslide); | console.log('ds '+diaslide); | ||
console.log('an '+anchor); | console.log('an '+anchor); | ||
Line 262: | Line 262: | ||
} | } | ||
− | + | function gup( name, url ) { | |
− | + | if (!url) url = location.href | |
− | + | name = name.replace(/[\[]/,"\\\[").replace(/[\]]/,"\\\]"); | |
− | + | var regexS = "[\\?&]"+name+"=([^&#]*)"; | |
− | + | var regex = new RegExp( regexS ); | |
− | + | var results = regex.exec( url ); | |
− | + | return results == null ? null : results[1]; | |
− | + | } | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | } | + | |
function funWithColi() { | function funWithColi() { |
Revision as of 00:14, 19 September 2015
![](https://static.igem.org/mediawiki/2015/b/ba/Team_Tuebingen_menu_coli_mit_lightstrahl.png)
<
>