I have some an ajax script running that lets users search a dbase table of contacts and then click on the contact to whom they want to email some text. The link to send the text to the contact is just an anchor link in the results with the text passed as a variable in the url. Then on the server side, the server emails the text to the contact's email address.
The problem I have is that if the text exceeds a certain length instead of remaining hidden in the url, it becomes visible on the page. Then the script no longer works correctly. At first, I thought the problem might be due to a special character in the text corrupting the url of the anchor link but that doesn't seem to be it...It's just a matter of length.
I found this posting
that says there is not supposed to be a limit to the querystring. However, In my case, the problem occurs even before trying submit the querystring as it pops out of the url and is visible on the page. Since it is in an url going to the server I cannot think of a good way to pass the lengthy text value outside the url,
Has anyone run across this problem and if so can you suggest a workaround?
Here is example.
a href="sendemail.php?contactid=33&text=HERE IS SOME SHORT TEXT">Send to Harry</a> //works
a href="sendemail.php?contactid=33&text=HERE IS SOME REALLY LONG TEXT THAT GOES ON AND ON.....ON AND ON.... ON AND ON....ON AND ON....PAST A FEW HUNDRED CHARACERS">Send to Harry</a> // "HERE IS SOME REALLY LONG TEXT etc." IS VISibLE ON PAGE