Manipulate HTML tags with DOMDocument

Reference:

  1. https://www.awaimai.com/2113.html
  2. https://stackoverflow.com/questions/16127142/modify-html-attribute-with-php
  3. https://stackoverflow.com/questions/2385834/php-dom-get-all-attributes-of-a-node