必须填写验证与Safari浏览器5.1 [英] Required Field Validator with Safari 5.1

查看:283
本文介绍了必须填写验证与Safari浏览器5.1的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是必填字段校验器(以下code)与一个向导中的单选按钮列表,以确保用户选择继续到向导的下一个步骤之前的值。这是工作的罚款,除了Safari浏览器所有浏览器。即使当用户已经选择了一个值从无线电按钮列表的验证错误消息正在示出,而不是让用户继续。我不明白,为什么这可能是为什么它可能只对Safari浏览器。

任何建议

 < ASP:的WizardStep ID =WizardStep2=服务器标题=第二步>
            以下是您的搜索结果中,选择一个出版物继续或再次搜索。
             < BR />< BR />
                    < ASP:单选按钮列表ID =rbl_publication=服务器>
                    < / ASP:单选按钮列表>
            < ASP:使用RequiredFieldValidator ID =pub_list_valid=服务器
                的ControlToValidate =rbl_publication
                的ErrorMessage =**请选择刊物> **请选择刊物< / ASP:使用RequiredFieldValidator>
            < BR />
            < ASP:标签ID =lbl_publications_no_data=服务器
                风格=字体重量:700
                文本=对不起......不出版物可供选择的标准,请重试。
                可见=假>< / ASP:标签>< BR />< BR />
        < / ASP:的WizardStep>
 

解决方案

我在Safari 5.0.5和5.1(视窗)测试,它将按预期工作。我要去猜测您的问题相关数据。你的HTML编码出版物标题?如果没有,那么你或许应该的。

希望这有助于

I'm using a Required Field Validator (code below) with a Radio Button List within a Wizard to ensure the user selects a value before proceeding to the next step of the wizard. This is working fine with all browsers except for Safari. Even when the user has selected a value from the Radio Button List the Validation Error Message is being shown and not allowing the user to proceed. I cannot figure out why this might be and why it might only be for Safari.

Any suggestions

            <asp:WizardStep ID="WizardStep2" runat="server" Title="Step 2">
            Below are the results of your search, select a publication to continue or search again.
             <br /><br />
                    <asp:RadioButtonList ID="rbl_publication" runat="server">
                    </asp:RadioButtonList>
            <asp:RequiredFieldValidator ID="pub_list_valid" runat="server" 
                ControlToValidate="rbl_publication" 
                ErrorMessage="** Please select a publication">** Please select a publication</asp:RequiredFieldValidator>
            <br />
            <asp:Label ID="lbl_publications_no_data" runat="server" 
                style="font-weight: 700" 
                Text="Sorry...No publications are available for the selected criteria, please try again." 
                Visible="False"></asp:Label><br /><br />
        </asp:WizardStep>

解决方案

I've tested on safari 5.0.5 and 5.1 (windows) and it works as expected. I'm going to guess that your issue is data related. Are you html encoding the publication titles? If not, then you probably should be.

Hope this helps

这篇关于必须填写验证与Safari浏览器5.1的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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