User:WOSlinkerBot/tabletidy.js: Difference between revisions

Content deleted Content added
WOSlinkerBot (talk | contribs)
No edit summary
WOSlinkerBot (talk | contribs)
No edit summary
 
(One intermediate revision by the same user not shown)
Line 134:
myContent = myContent.replace(/(\{\| *class\=\"wikitable plainrowheaders\") (border|cellpadding|cellspacing)\=\"\d*\" (border|cellpadding|cellspacing)\=\"\d*\"/g,'$1');
myContent = myContent.replace(/(\{\| *class\=\"wikitable plainrowheaders\") (border|cellpadding|cellspacing)\=\"\d*\"/g,'$1');
 
myContent = myContent.replace(/\{\| *class\=\"wikitable\" (width\=\"\d*\%\") *border\=\"\d\" *cellpadding\=\"\d*\" *cellspacing\=\"\d*\" *style\=\"background\: *\#f9f9f9\; *border\: *1px solid \#aaaaaa\; *border-collapse\: *collapse\; */g,'{| class="wikitable" $1 style="');
 
myContent = myContent.replace(/\{\| *class\=\"wikitable\" (width\=\"\d*\%\") *cellpadding\=\"\d*\" *cellspacing\=\"\d*\"/g,'{| class="wikitable" $1');
myContent = myContent.replace(/\{\| *class\=\"wikitable\" (width\=\"\d*\%\") *border\=\"\d\" *cellpadding\=\"\d*\" *cellspacing\=\"\d*\"/g,'{| class="wikitable" $1');
 
if(document.getElementById('wpTextbox1').value != myContent) {