A simple module to regenerate safely image with AJAX