Odd Dynamic Script being inserted into page...

4 posts, 0 answers
  1. Andrew
    Andrew avatar
    39 posts
    Member since:
    Feb 2011

    Posted 08 Nov 2011 Link to this post

    When using a WebService-populated menu, as items get added, or branches opened (I can't work out the exact trigger). I get new dynamic script entries being put into the page - the script is simply :

    ' ' ;

    In case that doesnt come out - its two single quotes, and a semi colon.

    Its not that much of a worry - but when the menu is cached fully - there could be hundreds of these entries...
  2. Kate
    Admin
    Kate avatar
    1898 posts

    Posted 11 Nov 2011 Link to this post

    Hello Andrew,

    I am not quite sure that I understand what the issue that you encounter is. Can you please record a video of how to reproduce it (you could use Jing for instance) and send it back to us so we can test it?

    Kind regards,
    Kate
    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
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Andrew
    Andrew avatar
    39 posts
    Member since:
    Feb 2011

    Posted 30 Nov 2011 Link to this post

    I've found where the script is getting infected into the page. There is an iFrame associated with every flyout menu that is created, and it has its src property set to "javascript:'';"
    <div class="rmSlide" style="left: 150px; top: 0px; width: 154px; height: 89px; overflow: hidden; display: none; visibility: visible; z-index: 7;">
        <iframe style="border: 0px currentColor; left: 0px; top: 0px; width: 0px; height: 0px; filter: progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0); position: absolute;" tabIndex="-1" src="javascript:'';" frameBorder="0">Your browser does not support inline frames or is currently configured not to display inline frames.
        </iframe>

    You see it in Visual Studio in the solution explorer window when running, in the Script Documents section...  I'd also question the amount of inline styles, and the 'no frames' message which is also injected into the page - increasing the source HTML size greatly with very large menu's (like ours)...

    I've attached a screen snap of the issue in VS.
  5. Peter
    Admin
    Peter avatar
    6637 posts

    Posted 02 Dec 2011 Link to this post

    Hi Andrew,

    If your concern is performance, then I suggest you review the top performance tips - http://www.telerik.com/products/aspnet-ajax/getting-started/top-performance.aspx, especially the usage of
    RadScriptManager and RadStyleSheetManager which combine scripts and style sheets respectively.

    If you encounter any errors or specific problems, please elaborate so we can get a better understanding of the issue.

    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
Back to Top