I have created a CloudPage for when the user clicks the "YES" CTA button that should be captured and redirect to the URL.
I have done the following and I am able to capture the response and update in the Lead object but can't redirect to the URL. Can someone tell me how to redirect to the URL when the page loads?
%%[
SET @Id = RequestParameter("Id")
SET @Response =RequestParameter("Response")
SET @upload = UpdateSingleSalesforceObject("Lead",@Id,"Consultation_Attended__c",@Response)
]%%
%%[IF @Response =="Yes" THEN ]%%
%%=RedirectTo("www.google.com")=%%
%%[ELSE]%%
%%=RedirectTo("www.yahoo.com")=%%
%%[ENDIF]%%
%%=v(@upload)=%%