View Single Post
  #2 (permalink)  
Old January 21st, 2011, 07:54 AM
digitalsoul digitalsoul is offline
Registered User
 
Join Date: Aug 2009
Posts: 5
Thanks: 0
Thanked 2 Times in 2 Posts
Default Solved it. Appears to be code error in Kindle edition

In the Kindle edition the lines:

Code:
 
ObjectStateFormatter stateFormatter = new ObjectStateFormatter();
page.ClientScript.RegisterHiddenField("__CSRFTOKEN", 
                        stateFormatter.Serialize(csrfToken));
Only get run if __CSRFCOOKIE already has a value, which it doesnt on first request.

If I move these lines outside of the if else block then the code works. Could the author confirm if this error does exist?

Thanks