upload img code by handler and config.