IE problem rendering node url containing anchor name

2 posts, 0 answers
  1. efter
    efter avatar
    3 posts
    Member since:
    Nov 2008

    Posted 10 Jun 2009 Link to this post

    I'm having a problem with rendering my treeview control in IE (I've tested on IE8, 7 & 6).

    My node urls point to a various content pages, some of which may also have an anchor name in order to navigate to an anchor within the target content page, such as in the example below:

    radTreeNode.NavigateUrl = "examplecontentpage.aspx#navigate to section"

    However this example has spaces in the anchor name, IE seems to replace the space character with '%20' which when clicked results in the page not being able to navigate to the anchor on the target page. Neither Firefox and Chrome seem to have this behaviour, neither replace the space character and both navigate to the anchor correctly. Also, I have content pages where this same link may exist elsewhere on the page (outside of the treeview control) and the anchor works fine in IE, so this behaviour seems to be specific to the treeview control in IE.

    Any ideas if/how I may resolve this without resorting to having to amend all anchor names?
  2. Paul
    Admin
    Paul avatar
    4281 posts

    Posted 10 Jun 2009 Link to this post

    Hello efter,

    Best way to avoid such problems is to follow standard naming practices for page names, downloadable files, music, anchors, subdirectories, images, and anything you point to that can become part of a webpage address.
    • Use lowercase, avoid caps if possible. Some servers will see mypage.htm and MyPage.htm as two different pages and others consider it to be the same page! If you are currently on a server that says they are the same and move your site to one that knows they are different, your links WILL NOT WORK.
    • DO NOT use SPACES in the names. Browsers do not allow spaces in URL addresses so don't do it.
    • DO NOT use SYMBOLS in the names. With the exception of (underline). Worst violation! Browsers do not allow symbols in URL addresses.
    • Keep them short as possible. Really long names can make linking difficult.

    Regards,
    Paul
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Back to Top