提交HTML code,而不设置validateRequest为false [英] Submitting html code without setting ValidateRequest to false

查看:121
本文介绍了提交HTML code,而不设置validateRequest为false的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个文本框,我希望用户能够提交一个YouTube嵌入code。 这是可能的,而不设置ValidateRequest'假?

I have a textbox and i want the user to be able to submit a youtube embed code. Is this possible without setting 'ValidateRequest' to false?

推荐答案

的Html EN code中的文本,并把它放在一个隐藏的输入前提交, 然后去code到服务器上后提交。

Html encode the text and put it in a hidden input before submit, and then decode it on the server after submit.

这篇关于提交HTML code,而不设置validateRequest为false的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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