This is a migrated thread and some comments may be shown as answers.

RadButton not responding in FireFox with FormsAuthentication

11 Answers 103 Views
Button
This is a migrated thread and some comments may be shown as answers.
Remco
Top achievements
Rank 1
Remco asked on 16 Sep 2014, 06:09 AM
Hi,

I created a login page with ASP.NET AJAX for a web application and it works flawless in IE, Chrome, Safari and FireFox. However, when I activated FormsAuthentication and performed some tests I noticed that the RadButton control in de Login Page is not responding in FireFox. I do see the button border changing when I hover over the mouse, but there is no response when I click the button. The DefaultButton-option is also not working. 

Visual Studio code:
<div>
  <telerik:RadButton id="button_submit" runat="server" BackColor="#0072c6" Text="Sign In" SingleClick="true" SingleClickText="Sign In" Skin="Metro" ButtonType="LinkButton" Style="padding:4px 10px 5px 10px; margin: 5px 0; color: #fff " OnClick="ButtonSubmitClick" ></telerik:RadButton>
</div>

Browser inspection:
<div>
  <span id="button_submit" class="RadButton RadButton_Metro rbLinkButton" style="background-color:#0072C6;padding:4px 10px 5px 10px; margin: 5px 0; color: #fff "><span class="rbText">Sign In</span><input id="button_submit_ClientState" name="button_submit_ClientState" type="hidden"></span>
</div>

Any idea, how to solve this?


 


11 Answers, 1 is accepted

Sort by
0
Danail Vasilev
Telerik team
answered on 18 Sep 2014, 12:30 PM
Hi Remco,

I wasn't able to reproduce the mentioned issue with RadButton. If you are not using the latest official Telerik UI version - 2014.2.724, does upgrading to it fixes the problem?

If the above step, however, do not help it would be better to try to reproduce the issue with the attached example and then tell us what changes you have made, so that I can proceed further with the examination.

Regards,
Danail Vasilev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Remco
Top achievements
Rank 1
answered on 18 Sep 2014, 01:39 PM
Hi Danail,

Thanks for your example. Page is working fine without FormsAuthentication, but when I activate the FormsAuthentication a buttonclick never triggers the ButtonSubmitClick() in FireFox.

Checked my system and I have the portable version of FireFox 32.0.1 installed. Should that be a problem?

Regards, Remco
0
Remco
Top achievements
Rank 1
answered on 18 Sep 2014, 02:22 PM
I forgot to mention that I'm using Telerik.Web.UI v4.0.30319. As far as I can see that is the latest version 2014.2.724.45.

Regards, Remco
0
Misho
Telerik team
answered on 23 Sep 2014, 01:54 PM
Hello,

Thank you for the additional details that you have provided. I've tried to replicate the issue in FireFox 32.0.1 but no avail. Could you please collaborate a bit more so that we will be able to isolate the issue and provide you with feedback for our further research?
I've crated a complete sample runnable website containing the scenario that could be found in the attachment.
This project contains a configuration using Telerik RadButton as well as the same scenario using ASP button. Please confirm whether you could replicate the same problems with ASP button on your side as well.
In addition please edit and modify the attached project in accordance to your setup with FormsAuthentication enabled and send it back to us so we will research it locally on our side.

Looking forward to your reply.

Regards,
Misho
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Remco
Top achievements
Rank 1
answered on 23 Sep 2014, 02:42 PM
Hi Misho,

I created a new project and incorporated your source code, and it worked fine.

Then I replaced the asp:ScriptManager with the telerik:RadScriptManager, because that's what we did in our Login Page. The browser stopped with an error because I forgot to add 'Telerik_Web_UI_WebResource_axd' to the Web.Config file. So I updated my Web.Config, and... the Login-button no longer triggers the ButtonSubmitClick().

Below you'll find the elements I added to de Web.Config. I probably did something wrong?

<system.webServer>
 
    <validation validateIntegratedModeConfiguration="false" />
    <handlers>
      <add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" />
    </handlers>
 
    <defaultDocument>
      <files>
        <clear />
        <add value="main.aspx" />
      </files>
    </defaultDocument>
 
  </system.webServer>


Regards, Remco

0
Remco
Top achievements
Rank 1
answered on 23 Sep 2014, 02:53 PM
BTW: replacing the telerik:RadScriptManager with asp:ScriptManager solved the issue in our Login Page.

Regards, Remco
0
Danail Vasilev
Telerik team
answered on 26 Sep 2014, 03:23 PM
Hello Remco,

I am still unable to reproduce the mentioned issue by implementing your modifications(i.e., using RadScriptManager and adding web.config settings). You can watch the short video test in the attached archive and then tell me if I am missing something.

The FireFox version under which I have made the test is the latest official one 32.0.3 and Telerik UI controls version is also the latest official one - 2014.2.724.

I have attached the full runnable VS project with the trial version of Telerik UI. Can you try reproducing the problem with this project and then tell us what is the result? Can you also provide us with the following information:
   - Is the issue reproducible when  you open the page from Visual Studio or from IIS?
   - Are there any JavaScript errors on your page that could break the proper functionality of the script controls on your page? If there are such errors they must be found and fixed?
   - Is the issue reproducible in other major browsers as well?
   - You can try the troubleshooting steps from the following aritcles:



Regards,
Danail Vasilev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Remco
Top achievements
Rank 1
answered on 27 Sep 2014, 10:31 AM
Hello Danail,

Thanks for your response, but I think it is easier if I explain the steps that finally causes the issue, and send you a link to the sourcecode of my sample Web Application. 

First I created a Web Application based on Misho's example. I used <asp:ScriptManager> as he did in his example. I activated the Forms Authentication via Web.config and it all seemed to work.

Then I replaced the <asp:ScriptManager> with the <telerik:RadScriptManager> in main.aspx (login page) and default.aspx (home page). When I run the Application I got the error telling me that '~/Telerik.Web.UI.WebResource.axd' is missing in web.config. So I added the following handler to the Web.Config:

<validation validateIntegratedModeConfiguration="false" />
 <handlers>
   <add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" />
 </handlers>


Now I was able to run the Web Application but I noticed two issues:
1. In FireFox the RadButton is not triggering the ButtonSubmitClick() (screenshot 1)
2. When I start the Web Application in IE and press the Refresh button or F5-key (screenshot 2) I get a Javascript critical error (screenshot 3 and error message below). Chrome and FireFox both respond without a Javascript error.

JavaScript critical error at line 3, column 1 in
http://localhost:51093/main.aspx?ReturnUrl=/Telerik.Web.UI.WebResource.axd?_TSM_HiddenField_=RadScriptManager_TSM&compress=1&_TSM_CombinedScripts_=%3b%3bSystem.Web.Extensions%2c+Version%3d4.0.0.0%2c+Culture%3dneutral%2c+PublicKeyToken%3d31bf3856ad364e35%3anl-NL%3a4ae4914f-8c8e-4123-9d05-414d87b48357%3aea597d4b%3ab25378d2%3bTelerik.Web.UI%2c+Version%3d2014.2.724.45%2c+Culture%3dneutral%2c+PublicKeyToken%3d121fae78165ba3d4%3anl-NL%3a6915a8c2-c063-435a-ab31-d2d2285652a6%3a16e4e7cd%3ab7778d6c%3af7645509%3a24ee1bba%3a6d43f6d9&_TSM_HiddenField_=RadScriptManager_TSM&compress=1&_TSM_CombinedScripts_=;;System.Web.Extensions,+Version=4.0.0.0,+Culture=neutral,+PublicKeyToken=31bf3856ad364e35:nl-NL:4ae4914f-8c8e-4123-9d05-414d87b48357:ea597d4b:b25378d2;Telerik.Web.UI,+Version=2014.2.724.45,+Culture=neutral,+PublicKeyToken=121fae78165ba3d4:nl-NL:6915a8c2-c063-435a-ab31-d2d2285652a6:16e4e7cd:b7778d6c:f7645509:24ee1bba:6d43f6d9\n\nSCRIPT1002:
Syntaxisfout

Maybe I made a mistake when I added the axd-reference to the Web.config. Hopefully you're able to tell me what I did wrong.


DL Link Web Application (VS2013): https://www.dropbox.com/s/8kszb0rqp0ihong/Telerik.FireFox.FormsAuth.Issue.zip?dl=0 

Regards, Remco

0
Remco
Top achievements
Rank 1
answered on 29 Sep 2014, 12:36 PM
Hello Danail, Misho,

Any workaround/solution how to fix this issue?

Today I found an additional problem with Chrome and FireFox in our application, that I did not notice before, because I use IE during development.

When I start our and the test application in Chrome I suddenly noticed the red cross in the url bar. It shows the same error I had in IE (see screenshot).

In our application I was able to overcome the error by not pressing the F5 immediately, but the error always occur in Chrome en FireFox, even when I do not refresh. As a result of that the Text-property of the RadInputBox controls is always empty and the login keeps failing.

Can you please have a look at my tiny Web Application asap and tell me what is the problem, because this is really giving me a bad feeling about the Rad-controls.

Regards, Remco
0
Remco
Top achievements
Rank 1
answered on 30 Sep 2014, 06:50 PM
Hello,

Still hope to hear any suggestion from Telerik support, but I just wanted to share my workaround.

Replacing telerik:RadScriptManager with asp:ScriptManager in the login-page all (hidden) errors were resolved. The login form is properly working in all earlier mentioned browsers. 

Regards, Remco
0
Danail Vasilev
Telerik team
answered on 01 Oct 2014, 02:15 PM
Hi Remco,

Thank you for providing us with a runnable project that reproduces the issue.

It seems that the website denies access to all pages to unauthorized users so the access to the Telerik.Web.UI.WebResource.axd handler is also unauthorized:
web.config:
<system.web>
 
  <compilation debug="true" targetFramework="4.5" />
  <httpRuntime targetFramework="4.5" />
 
  <authentication mode="Forms">
    <forms loginUrl="main.aspx" protection="All" path="/" timeout="30" />
  </authentication>
 
  <authorization>
    <deny users ="?" />
    <allow users = "*" />
  </authorization>
   
</system.web>


This in turn causes the handler to serve the content of the login page instead of the combined scripts, hence the error.

In order to handle this error I can suggest that you add a <location> section to the application configuration file to allow access to Telerik.Web.UI.WebResource.axd to all users:

web.config:
<configuration>
  <location path="Telerik.Web.UI.WebResource.axd">
    <system.web>
      <authorization>
        <allow users="*"/>
      </authorization>
    </system.web>
  </location>
  <system.web>
 
    <compilation debug="true" targetFramework="4.5" />
    <httpRuntime targetFramework="4.5" />
 
    <authentication mode="Forms">
      <forms loginUrl="main.aspx" protection="All" path="/" timeout="30" />
    </authentication>
 
    <authorization>
      <deny users ="?" />
      <allow users = "*" />
    </authorization>
     
  </system.web>
 
  <system.webServer>
 
    <validation validateIntegratedModeConfiguration="false" />
    <handlers>
      <add name="Telerik_Web_UI_WebResource_axd" verb="*" preCondition="integratedMode" path="Telerik.Web.UI.WebResource.axd" type="Telerik.Web.UI.WebResource" />
    </handlers>
 
    <defaultDocument>
      <files>
        <clear />
        <add value="main.aspx" />
      </files>
    </defaultDocument>
 
  </system.webServer>
 
   
</configuration>

More information on the matter is available in the General Troubleshooting help article, in the section called "Using the Telerik controls with RadScriptManager on your login page throws an error".

Regards,
Danail Vasilev
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Button
Asked by
Remco
Top achievements
Rank 1
Answers by
Danail Vasilev
Telerik team
Remco
Top achievements
Rank 1
Misho
Telerik team
Share this question
or