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

RadMenu & Microsoft AntiXss 4.2.1

2 Answers 95 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Richard Weeks
Top achievements
Rank 2
Richard Weeks asked on 18 Jan 2012, 03:12 AM
If I reference the AntiXss library (4.2.1) and then implement it through web config, e.g:
<system.web>
    <httpRuntime encoderType="Microsoft.Security.Application.AntiXssEncoder, AntiXssLibrary"/>
</system.web>

When rendered, the RadMenu presents all links as href="%23".

How can I ensure RadMenu operates normally after adding AntiXss?

Richard

2 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 20 Jan 2012, 04:49 PM
Hello Richard,

The problem is not with RadMenu. You can test a regular HyperLink and its NavigateUrl value will also get corrupted:
* * *
 
 <asp:HyperLink Text="aaaa" NavigateUrl="http://www.google.bg/" runat="server"></asp:HyperLink>
 
* * *

You can try to workaround the issue with the client API of RadMenu:
<script type="text/javascript">
        function OnClientLoad(menu) {
            var items = menu.get_allItems();
            for (var i = 0; i < items.length; i++) {
                var currentItem = items[i]
                currentItem.set_navigateUrl(currentItem.get_navigateUrl());
            }       
        }
    </script>
    <telerik:RadMenu ID="RadMenu1" runat="server" OnClientLoad="OnClientLoad">


Kind regards,
Peter
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
0
Richard Weeks
Top achievements
Rank 2
answered on 22 Jan 2012, 11:26 PM
It's a bug. Damn, there goes my AntiXss till they get a patch out :(

Richard
Tags
Menu
Asked by
Richard Weeks
Top achievements
Rank 2
Answers by
Peter
Telerik team
Richard Weeks
Top achievements
Rank 2
Share this question
or