在没有ViewState的回发过程中保留数据...... [英] preserve data during postbacks without ViewState ......

查看:88
本文介绍了在没有ViewState的回发过程中保留数据......的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要保留Asp.Net页面中HTML内容的回发之间的数据,而无需使用viewstate,session,缓存或隐藏字段.

我有什么选择?

I need to preserve the data between postbacks for HTML content in an Asp.Net page without using viewstate, sessions, caching or hidden fields.

What are my options?

推荐答案



如果您不关心安全性,则可以考虑查询字符串,但是可以存储的数据大小是有限制的.



您也可以考虑使用cookie,以在请求之间存储数据,但这将存储在客户端.

希望对您有所帮助!.

问候,
-Vinayak
Hi,

If security is not your concern, you can think about the query string, However there is a limit in terms of the size of the data you can store.

Or

You can also think about the cookies, to store the data between the request, but this will be stored at the client side.

I hope this helps!.

Regards,
-Vinayak


好吧,您几乎消灭了那里的所有选择!将其存储在XML文件中吗?还是在数据库中?

您要这样做的原因是什么?
Well you pretty much wiped out every choice there! Store it in an XML file? Or in a database, perhaps?

What is your reason for wanting to do this?


在这里看看: ^ ]

选择适合您的一个.
Have a look here: ASP.NET State Management Overview[^]

Pick the one that suits you.


这篇关于在没有ViewState的回发过程中保留数据......的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆