I have a problem...I have a classified adds web app. This if what is
happening:
1. The user enters the site
2. The user checks one of the adds. This web page has a user control that
load similar adds to the one the user has currently selected, in this same
user control there is a form so the user can contact the seller. So when the
page loads, all the contact information of the seller is loaded into this
user control, exept the email address that is loaded into a var so no email
"fhishers" can grab the address.
3. The user goes and checks one of the similar adds shown on the similar
adds list in that user control.
4. The user decides to go back and contact the seller from the first add he
saw, but he only hits the back button on the browser, so no data reloads on
the previous page and the variable with the sellers email address still has
the value from the second add, not the firs one (wich he intends to contact
the seller) so the contact message goes to another person.
PLEASE HELP!
TIA!
Joerg Jooss - 17 Feb 2006 19:14 GMT
Thus wrote TCB,
> I have a problem...I have a classified adds web app. This if what is
> happening:
[quoted text clipped - 24 lines]
> the seller) so the contact message goes to another person.
> PLEASE HELP!
You could try to make your pages non-cacheable, but that doesn't work across
all browsers:
Response.Cache.SetCacheability(HttpCacheability.NoCache);
A safer approach is not to cache the E-Mail address at all, but retrieve
it only when it's required.
Cheers,

Signature
Joerg Jooss
news-reply@joergjooss.de
blackstaronline.net - 17 Feb 2006 20:05 GMT
I'm with Joerg on this one. That "should" (theres always exceptions)
make the page load completely again after the uesr hits the back
button. This should auto-fill your information for the correct seller.
Also, Joerg is correct with the email address. If its not something
your displaying on the screen then don't pull it until you need it.
Jeremy Reid
http://blackstaronline.net/hgtit
TCB - 17 Feb 2006 20:36 GMT
Thank you both! =)
I found that if I save the Email address in the viewstate of the usercontrol
this seems to work. But if someone thinks that that is unsafe of could not
work sometimes, please let me know.
Thanks again.
> I'm with Joerg on this one. That "should" (theres always exceptions)
> make the page load completely again after the uesr hits the back
[quoted text clipped - 4 lines]
> Jeremy Reid
> http://blackstaronline.net/hgtit