htmlentities in PHP but preserving html tags

You can get the list of correspondances character => entity used by htmlentities, with the function get_html_translation_table ; consider this code : $list = get_html_translation_table(HTML_ENTITIES); var_dump($list); (You might want to check the second parameter to that function in the manual — maybe you’ll need to set it to a value different than the default one) … Read more

How to use python-docx to replace text in a Word document and save

UPDATE: There are a couple of paragraph-level functions that do a good job of this and can be found on the GitHub site for python-docx. This one will replace a regex-match with a replacement str. The replacement string will appear formatted the same as the first character of the matched string. This one will isolate … Read more