Skip to content

Instantly share code, notes, and snippets.

EMAIL-GREP-PATTERN
<!-- Please remove all commented out code before using. Visit https://gist.github.com/ccstone/5385334 for more regular expressions available in TextWrangler -->
<!-- \r is line break, \s is non whitespace, \t tab, this looks for table cells and image tags with missing attributes -->
|<td>|<td>\r*?\s*?\t*?<img|(<img\s*(?!.*\r*?.*?\r*?.*?display: ?block.*?\r?))
<!-- image formatting and styles: height, width, block, alt text -->
|<img\s*(?!.*\r*?.*?\r*?.*?height.*?\r?)|<img\s*(?!.*\r*?.*?\r*?.*?width.*?\r?)
<!-- break tag variants -->
|<br/>|<br>
<!-- special characters -->