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

telerik scripts and authentication?

1 Answer 104 Views
Window
This is a migrated thread and some comments may be shown as answers.
Sam
Top achievements
Rank 1
Sam asked on 09 May 2011, 04:04 PM
Hi,

I'm trying to use a radwindow on a log in page.
The page works fine when authentication is off.
Soon as I enable authentication, the window will not show.

I don't need to open/close/manipulate the window...I just need it to stay visible at all times.

SignIn.aspx :
<telerik:RadScriptManager ID="RadScriptManager1" runat="server" LoadScriptsBeforeUI="true" ScriptMode="Release">
</telerik:RadScriptManager>
<telerik:RadWindowManager ID="RadWindowManager1"
    runat="server"
    EnableViewState="true"
    EnableShadow="true"
    Modal="true"
    VisibleStatusbar="false"
    PreserveClientState="true"
    Animation="Fade"
    Behaviors="None"
    DestroyOnClose="True"
    EnableEmbeddedScripts="true"
    VisibleOnPageLoad="true"
    KeepInScreenBounds="True">
    <Windows>
        <telerik:RadWindow ID="RadWindow1" runat="server">
            <ContentTemplate>
                Hello!
            </ContentTemplate>
        </telerik:RadWindow>
    </Windows>
</telerik:RadWindowManager>


If no authentication, the page works fine.
As soon as I add the below to the web.config file, the window no longer shows:
<authentication mode="Forms">
    <forms name="SecLogin" path="/" loginUrl="SignIn.aspx" timeout="200"/>
</authentication>
<authorization>
    <deny users="?"/>
</authorization>

1 Answer, 1 is accepted

Sort by
0
Accepted
Marin Bratanov
Telerik team
answered on 11 May 2011, 03:22 PM

Hi Sam,

The authentication disables access to all files, but the login page and thus the WebResource that the RadControls use to load their JavaScript files is not loaded, which prevents them from working. The solution is to allow the WebResource to be accessed:

<location path="Telerik.Web.UI.WebResource.axd">
  <system.web>
    <authorization>
      <allow users="?"/>
    </authorization>
  </system.web>
</location>

This path is used when the RadScriptManager is used, if the regular asp ScriptManager is used you only need to add "WebResource.axd".

You can find my test project attached with the full web.config (although very simple since there is no actual logic in the site).



Regards,
Marin
the Telerik team

Browse the vast support resources we have to jump start your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.

Tags
Window
Asked by
Sam
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or