Image Embedder is a php shell utility that will search your HTML/xHTML document for image files and embed the ones that are less than 50kb back into the html document. Nothing will be deleted, your input files will be backed up as an .old file so you can always reverse the process later if it doesn't work out for you.
$ php site_scanner.php --help
$ php site_scanner.php --scan
$ php site_scanner.php file.html [max file size]
When you need to send an HTML page to somebody, it may be a complicated process if it uses images or other resources as external files. In that case all the external resources need to be bundled with the main HTML page.
This class implements an alternative solution to avoid needing to bundle external files as separate files.
It replaces all image tags with data URLs that contain the actual image data embedded in the same HTML document, so the images no longer need to be retrieved from separate files.