You need to sign in to do that
Don't have an account?
Pierre-Etienne
'&' charater problem in S-Control
I wrote a S-Control to add a button that will create a new contact while passing some additional fields from the Account. The problem is that if the account name has '&' character. When I call the S-control, the Contact created has the account name truncated. I tried to add single quote or double quote around {!Account.Name} but it did not work. Any idea?
Thanks
<script type="text/javascript" src="/js/functions.js"></script>
<script src="/soap/ajax/12.0/connection.js"></script>
<script language="JavaScript">
function redirect() {
parent.frames.location.replace("/003/e?retURL=%2F{!Account.Id}&con4={!Account.Name}&00N40000001acqc={!Account.Billing_County__c}&CancelURL=%2{!Account.Id}&ent=Contact")
}
redirect();
</script>
Thanks
<script type="text/javascript" src="/js/functions.js"></script>
<script src="/soap/ajax/12.0/connection.js"></script>
<script language="JavaScript">
function redirect() {
parent.frames.location.replace("/003/e?retURL=%2F{!Account.Id}&con4={!Account.Name}&00N40000001acqc={!Account.Billing_County__c}&CancelURL=%2{!Account.Id}&ent=Contact")
}
redirect();
</script>
<script type="text/javascript" src="/js/functions.js"></script>
<script src="/soap/ajax/12.0/connection.js"></script>
<script language="JavaScript">
function redirect() {
var Act = encodeURIComponent('{!Account.Name}');
parent.frames.location.replace("/003/e?retURL=%2F{!Account.Id}&con4="+Act+"&00N40000001acqc={!Account.Billing_County__c}&CancelURL=%2{!Account.Id}&ent=Contact")
}
redirect();
</script>