| |

VerySource

 Forgot password?
 Register
Search
Author: raingel

When I always submit articles, I always get this error: Let ’s take a look at 100 points!

[Copy link]

1

Threads

7

Posts

4.00

Credits

Newbie

Rank: 1

Credits
4.00

 China

 Author| Post time: 2020-1-5 09:57:01
| Show all posts
up
Reply

Use magic Report

0

Threads

64

Posts

35.00

Credits

Newbie

Rank: 1

Credits
35.00

 China

Post time: 2020-1-6 11:30:01
| Show all posts
If the article is very small, there is no problem submitting, if you use asp.net2.0, add this code to your page:

    protected override PageStatePersister PageStatePersister
    {
        get
        {
            return new SessionPageStatePersister (this);
        }
    }

Not only can this solve the problem, but the ViewState downloaded to the client has only a simple one-line encoding, and you will immediately feel that the page opens quickly.


If you are asp.net1.1, I posted a lot of methods to save ViewState in the server's temporary file directory, and combined with Cache for 10 seconds to speed up. That method is equally effective and reliable compared to using Session (even if the server is powered up and restarted, the client will not feel the state is lost). However, I have n’t used asp.net1.1 for a long time, and the code ca n’t be found. If you need to, you can follow the tips here to google to see if there is a similar function code.


The MAC check of this ViewState does not match, basically because the downloaded ViewState data is too large, and the data you submitted is also large, causing ViewState to not be completely sent back to the server (due to the maximum upload size MaxRequestLength, etc.), the server mistakenly thought it was The ViewState stored in the hidden field on the browser is modified by the "bad guy" on the client.
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list