Fixes getTabs() in readme.html to work on IE 11
d.innerHTML returns `<li class="Tab" id="MoreTab" ...` on IE 11, while the regex expects `<li id="MoreTab" ...` It seems like IE is changing the order of the attributes within the tags.
This commit is contained in:
parent
a2610427b9
commit
eadf68d3c3
@ -815,10 +815,10 @@ echo $data->longurl;</tt></pre>
|
||||
// Dynamically get tabs
|
||||
function getTabs() {
|
||||
var d = document.getElementById('Tabs');
|
||||
var matches = d.innerHTML.match(/<li id="(.+?)Tab"/g);
|
||||
var matches = d.innerHTML.match(/<li.* id="(.+?)Tab"/g);
|
||||
var tabs = []
|
||||
for (i in matches) {
|
||||
tabs[i]= matches[i].replace('<li id="','').replace('Tab"', '');
|
||||
tabs[i]= matches[i].replace(/<li.* id="/,'').replace('Tab"', '');
|
||||
}
|
||||
tabs = tabs.reverse();
|
||||
return (tabs)
|
||||
|
Loading…
x
Reference in New Issue
Block a user