Generate image url before validation