Question
Velocity Scripting with Segmentation
Hi,
I have this velocity working with segmentation. I'm able to get the first baseUrl populated, however the second baseUrl1 is not working. This is how it displays: ${url}/
#set( $AssetId = $mktmail.xMarketoIdHdr.split(":")[5] )
#set($utm_campaign = "utm_campaign=" + $esc.url($AssetId))
#set($utm_source="Nurture")
#set($utm_content="ABC")
#set($utm_term="CDE")
#set($utm_id = "utm_id=EFG")
#set($baseUrl = "www.abc.com?formid=001&utm_medium=Email&utm_source=$utm_source&utm_content=$utm_content&utm_term=$utm_term")
#set($baseUrl1= "www.abc.com?formid=002&utm_medium=Email&utm_source=$utm_source&utm_content=$utm_content&utm_term=$utm_term")
#if($lead.Segmentation_Test_1000.equals("Stuff"))
#set($url = $baseUrl+"&"+ $utm_campaign + "&" + $utm_id)
#elseif($lead.Segmentation_Test_1000.equals("Other Stuff"))
#set($url = $baseUrl1+"&"+ $utm_campaign + "&" + $utm_id)
#end
I've also tried including https:// protocol as well and still not working
Do you know what the reason might be? Thanks