Adjust IF statement for delivering URL