Content deleted Content added
Manishearth (talk | contribs) No edit summary |
Manishearth (talk | contribs) No edit summary |
||
Line 14:
par = getElementsByClassName(pre[i], "span", className);
for(j = 0; j < par.length; j++) {
par[j].innerHTML=par[j].innerHTML.replace(/\[\[([^\]\|]*)\]\]/g,"<a href='"+wgServer+wgArticlePath+"\
par[j].innerHTML=par[j].innerHTML.replace(/\[\[([^\]\|]*)[\|]?([^\]]*)\]\]/g,"<a href='"+wgServer+wgArticlePath+"'>$2</a>");
par[j].innerHTML=par[j].innerHTML.replace(/\[(http[s]?:[^\]\s]*)\]/g,"<a href=\'$1\'>$1</a>");
|