Add phpdoc, rename couple of methods.
Use pre-populated variables to do the replacing (faster).
Add phpdoc.
Add phpdoc.
Add phpdoc.
Add phpdoc.