buenas tardes a todos
estoy tratando de realizar una funcion que si detecta en que servidor esta manda un mail a tal destino, si esta en otro lo manda a otro
con esta funcion
<%
function correo_web()
direccion_correo = Request.ServerVariables("SERVER_NAME")
if direccion_correo = "sdbuetbweb01" then
direccion_valida = mySmartMail.Recipients.Add "[email protected]"
elseif direccion_correo = "ssatywebn2" then
direccion_valida = mySmartMail.Recipients.Add "[email protected]"
else
direccion_valida = mySmartMail.Recipients.Add "[email protected]"
end if
'correo_web = direccion_valida
end function
%>
pero cuando llamar la funcion me tira error
pero la unica forma en que el aspsmartmail me deja poner el destinatario es: mySmartMail.Recipients.Add "[email protected]"
alguien me da una idea de como solucionar esto??