Content deleted Content added
Manishearth (talk | contribs) No edit summary |
Manishearth (talk | contribs) No edit summary |
||
Line 43:
var h2=h+"";
var h3=h2+""
var h4=h3+"";▼
var q;
var quo;
Line 49 ⟶ 50:
q = /\"([^\"']*)\"/g;
quo='\"'
p = encodeURIComponent(h3.replace(q, "$1").replace(/[_\s]+/g, "_")).replace(/%2F/g, "/");▼
s.innerHTML = quo + '<a href=\"' + wgArticlePath.replace("$1", p) + '\">' + h4.replace(q, "$1") + '</a>' + quo;▼
}else if(h2.match(/'([^'\"]+)\'/)) {
q = /'([^'\"]*)'/g;
quo="\'"
p = encodeURIComponent(h3.replace(q, "$1").replace(/[_\s]+/g, "_")).replace(/%2F/g, "/");
s.innerHTML = quo + '<a href=\"' + wgArticlePath.replace("$1", p) + '\">' + h4.replace(q, "$1") + '</a>' + quo;
}else continue;
▲ var h4=h3+"";
▲ p = encodeURIComponent(h3.replace(q, "$1").replace(/[_\s]+/g, "_")).replace(/%2F/g, "/");
▲ s.innerHTML = quo + '<a href=\"' + wgArticlePath.replace("$1", p) + '\">' + h4.replace(q, "$1") + '</a>' + quo;
}
}
|