Developer forum
E-mail notifications
Strange Char problem
Posted on 16/01/2008 10:40:23
I have a strange problem when trying to log in on this site im working on.
http://rentamini.net.dynamicweb.dk/Default.aspx?ID=1
in the log in field below to the left if I enter a wrong code i get the char codes for the email when I return to the page fx if I enter user: fengel@gmail.com and password: 787878
I fill out the email formfield on return with the email to enable having the password sent.
But the string I get in return is the Char codes for the string.
fengel@gmail.com
Do you have an idea what may be the problem?
- Sune
Replies
Posted on 16/01/2008 11:18:17
HTML source on your page after submit contains rather suspicious JS snippet:
var sendTo ="foo@mail.com";
document.getElementById("email").value = "foo@mail.com";
So, it seems that you fill template tags with already encrypted chars. Try to debug your module.
var sendTo ="foo@mail.com";
document.getElementById("email").value = "foo@mail.com";
So, it seems that you fill template tags with already encrypted chars. Try to debug your module.
Nicolai Høeg Pedersen
Posted on 16/01/2008 15:22:23
In control panel, under security, you can check a checkboks with antispam function. It will encode the mail as described. They should still be shown normal though...? Try disable this feature and see what happens.
Posted on 16/01/2008 15:57:24
Thanx for the replies
It appears that the problem was with the '@'.
I still have no clue why it behaves like this (im pretty certain this is not the first time i write out an email to a templatetag.
I fixed it with this: master.SetTemplateValue("eMail", signInEmail.Replace("@", @"\@"));
#1 Why is that js snippet suspicious?
#2 Maybe I'll try to test your suggestion (if I have the time) but shouldnt it only encrypt emails?
kind regards Sune
It appears that the problem was with the '@'.
I still have no clue why it behaves like this (im pretty certain this is not the first time i write out an email to a templatetag.
I fixed it with this: master.SetTemplateValue("eMail", signInEmail.Replace("@", @"\@"));
#1 Why is that js snippet suspicious?
#2 Maybe I'll try to test your suggestion (if I have the time) but shouldnt it only encrypt emails?
kind regards Sune
Posted on 16/01/2008 16:07:34
NP wrote:OK I tested it and this was definitely the problem.In control panel, under security, you can check a checkboks with antispam function. It will encode the mail as described. They should still be shown normal though...? Try disable this feature and see what happens.
An input textbox cannot display html and that was the reason it appeared the way it did.
So I'll continue to use my hack as it is not too often I write a email to a templatetag in a textbox
So thanx for clarifying this.
- Sune
You must be logged in to post in the forum