I setup a very similar function, however, each time it redirects it fails. I noticed in the link that it ads a ?cf_id string to the end causing the link to fail. I don’t have any settings turned on for that to be passing anything through with the url. I checked to be sure any settings that would do this were turned off.