Use simpler (and faster) file_get_contents() on local if configured

Rather than doing a full HTTP request to get a local asset, just use
a quick file_get_contents() call to grab the HTML.