User:ArrowHead294/Regex snippets: Difference between revisions

ArrowHead294 (talk | contribs)
mNo edit summary
ArrowHead294 (talk | contribs)
mNo edit summary
Line 20: Line 20:
| Space out pipe characters and header separators<br />in tables (one cell per line)<br />Replace <code>!&nbsp;{{pipe}}&nbsp;</code> with <code>!&nbsp;</code> and <code>{{pipe}}&nbsp;{{pipe}}&nbsp;</code> with <code>{{pipe}}&nbsp;</code>
| Space out pipe characters and header separators<br />in tables (one cell per line)<br />Replace <code>!&nbsp;{{pipe}}&nbsp;</code> with <code>!&nbsp;</code> and <code>{{pipe}}&nbsp;{{pipe}}&nbsp;</code> with <code>{{pipe}}&nbsp;</code>
|-
|-
| <code><nowiki>(?<=\{\|.*?\n)(?<!\|-\n)(\||!)</nowiki></code>
| <code><nowiki>(?<=\{\|.*?\n(?:\|\+.*?\n)?)(?<!\|-\n)(\||!)</nowiki></code>
| <code><nowiki>|-\n$1</nowiki></code>
| <code><nowiki>|-\n$1</nowiki></code>
| Insert table cell separator at top of table before<br />first headers
| Insert table cell separator at top of table before<br />first headers