Master page_enableeventvalidation「建议收藏」

Master page_enableeventvalidation「建议收藏」Masterpage/contentpagepostbackproblemHi,Ihavethefollowingscenario:Iamusingamasterpage(masterpage.master)whichcontainsatextboxandtwoImagebuttonsasservercontrols.Itriedsom

大家好,又见面了,我是你们的朋友全栈君。

Master page/content page postback problem

Hi,

I have the following scenario:

I am using a masterpage (masterpage.master) which contains a textbox and two Imagebuttons as server controls. I tried some non-input content pages using this master page and everything is OK.

However, I have recently added a new content page which consists of an <asp:Wizard> and its steps, one of which contains <asp:textbox>es and some validation controls. The problem I am encountering, is: if the initial value of the textbox(es) is, say “abc” (set in <asp:WizardStep> html), even if I type this value to say, “hello” (when running) and put a breakpoint in the content page’s Page_load to see the value
after postback, it is still given as “abc” (even though I have typed “hello” in the textbox(es)).

I also noticed incidentally that if I remove ‘EnableEventValidation=”false”‘ from the masterpage, I get “Invalid postback or callback argument” error.

What I do not understand is that if I remove the master page (or use a different page with the content pasted in and no masterpage included) the change is registered after postback.

Could anyone please help?

Thanks in advance,

Timothy

Reply With Quote
  #
2  
Old 12-13-2006, 06:02 AM
timmym
timmym is offline <script type=”text/javascript”> vbmenu_register(“postmenu_469327”, true); </script>
Registered User
 
Join Date: Jun 2004
Location: Malta, Europe
Posts: 50

Solved!

OK! Solved the problem…it was that the master page had a <form runat=”server”> and a redundant <form> (without the runat=”server”; which came from the template I used) deeper down, which when removed, made everything work correctly!

 

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/163877.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • JMM内存模型介绍「建议收藏」

    JMM内存模型介绍「建议收藏」一、JMM的定义1.什么是JMM《Java虚拟机规范》中曾试图定义一种“Java内存模型”(JavaMemoryModel简称JMM)来屏蔽各种硬件和操作系统的内存访问差异,以实现让Java程序在各种平台下都能达到一致的内存访问效果。Java内存模型是一种抽象的概念,并不真实存在,它描述的是一组规则或规范,通过这组规范定义了程序中各个变量(包括实例字段,静态字段和构成数组对象的元素)的访问方式。JMM是围绕原子性,有序性、可见性展开。2.主内存与工作内存Java内存模型的主要目的是定义程

    2025年7月14日
    0
  • django 异常处理_django apscheduler

    django 异常处理_django apscheduler前言在讲解如何解决migrate报错原因前,我们先要了解migrate做了什么事情,migrate:将新生成的迁移脚本。映射到数据库中。创建新的表或者修改表的结构。问题1:migrate怎么判断哪

    2022年8月7日
    0
  • 自然语言处理简介(1)—- 服务梳理与传统汉语分词

    1.Nlp技术体系简介1.1基础技术1.2Nlp核心技术1.3NlP+(高端技术)2.知名NLP服务系统简介2.1汉语分词系统ICTCLAS2.2哈工大语言云(LanguageTechnologyPlatform,LTP)2.3AmazonComprehend2.4阿里云NLP2.5腾讯云NLP2.6百度语言处理基础技术2.6.1功能丰富且…

    2022年4月8日
    50
  • if sql语句_SQL IF语句介绍和概述

    if sql语句_SQL IF语句介绍和概述ifsql语句ThisarticleexplorestheusefulfunctionSQLIFstatementinSQLServer.本文探讨了SQLServer中有用的函数SQLIF语句。介绍(Introduction)Inreallife,wemakedecisionsbasedontheconditions….

    2022年7月16日
    18
  • 传统蓝牙HCI流控(HCI flow control)

    传统蓝牙HCI流控(HCI flow control)一.声明本专栏文章我们会以连载的方式持续更新,本专栏计划更新内容如下:第一篇:蓝牙综合介绍,主要介绍蓝牙的一些概念,产生背景,发展轨迹,市面蓝牙介绍,以及蓝牙开发板介绍。第二篇:Transport层介绍,主要介绍蓝牙协议栈跟蓝牙芯片之前的硬件传输协议,比如基于UART的H4,H5,BCSP,基于USB的H2等第三篇:传统蓝牙controller介绍,主要介绍传统蓝牙芯片的介绍,包括射频层(RF),基带层(baseband),链路管理层(LMP)等第四篇:传统蓝牙host介绍,主

    2022年6月6日
    91
  • 海思Hi3798MV100机顶盒芯片介绍[通俗易懂]

    海思Hi3798MV100机顶盒芯片介绍[通俗易懂]Hi3798MV100是海思推出的专门针对OTT机顶盒市场的高性价比芯片方案。在码流兼容性、在线视频播放的流畅性、图像质量以及整机性能方面保持业界最好的用户体验。集成四核高性能处理器、内置NEON,其处理性能可以满足各种差异化的业务需求,支持Dolby和DTS音频处理。支持H.265、H.264、AVS+、MVC、MPEG2、MPEG4、VC-1、VP6、VP8等多种格式的高清视频解码和高性…

    2022年6月15日
    86

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号