Suggestions for providing ResolveClientUrl() type functionality within content?

Last post 10-08-2007, 1:32 PM by Adam. 1 replies.
Sort Posts: Previous Next
  •  10-08-2007, 11:42 AM 34092

    Suggestions for providing ResolveClientUrl() type functionality within content?


    Any way to get access to the cool ResolveClientURL functionality to do something like <a href='~/Member/ContentPage.aspx'> ?

    I won't be able to guarantee whether my app will be a virtual directory or a root folder on a new site.  Therefore, doing something like <a href='/members/contentPage.aspx'>Example</a> won't always work for me.  Unfortunately, I also may not be able to guarantee where I'll be calling to the page, so using a ./members/contentPage.aspx won't work either.  What I'd really like to do is use the cool ~/Member/ContentPage.aspx notation allowed in .NET 2.0.  Has anyone else found a good workable solution for this?

    I've been digging into custom ExpressionBuilders but so far have had no luck.  Within CuteEditor, it looks like I can set the baseHREF but I think that means the content won't be portable from system to system.

    Please help. 

  •  10-08-2007, 1:32 PM 34093 in reply to 34092

    Re: Suggestions for providing ResolveClientUrl() type functionality within content?

    ddavison,
     
    <a href='~/Member/ContentPage.aspx'> is an application based path. It's an ASP.NET feature. But it only works in server side and it's a invalid path in browsers. When you use it, ASP.NET will convert this path to regular path automatically in server side.
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

View as RSS news feed in XML