+1-888-365-2779
Try Now
More in this section

Forums / Bugs & Issues / src attribute of internal images contain virtual directory name

src attribute of internal images contain virtual directory name

5 posts, 0 answered
  1. Mikael Kleinwort
    Mikael Kleinwort avatar
    78 posts
    Registered:
    17 May 2004
    28 Feb 2009
    Link to this post
    when I include an image in a page, the image source which is stored in the cms database contains not only the reference to the image, but also the name of the virtual directory which the project runs under.

    I guess the same applies to other content items as well.

    This seems to be an unneccessary complication. If I move the project to another webserver with anotehr virtual directory name or url, all of my internal image links are broken.

    This seems to me to be a design fault.

    Regards, Mikael

  2. Mikael Kleinwort
    Mikael Kleinwort avatar
    78 posts
    Registered:
    17 May 2004
    28 Feb 2009
    Link to this post
    Additional information:

    I was talking about images included in generic content, using the insert an image buttonof the Generic Content editor. I get this source attribute:

    src="/VirtualDirectoryName/Libraries/Library_Name/Picture_Name.sflb.ashx"

    Regards, Mikael

  3. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    03 Mar 2009
    Link to this post
    Hi Mikael Kleinwort,

    You are completely right.
    We are aware of that issue though and think for different way to resolve it. The problem is that if we resolve every single link, it should have some performance issue. However, I suggest you to use our ReplaceTool to change your links. When you deploy your application, you might run it like:

    Search For: /virtualdirectory/
    Replace with: /

    It will change the paths so they do not contain the virtual directory.

    As additional information, we will most probably use the sfref attribute in order to dynamically change the paths depending on the virtual directory as well.

    Kind regards,
    Georgi
    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.
  4. Mikael Kleinwort
    Mikael Kleinwort avatar
    78 posts
    Registered:
    17 May 2004
    03 Mar 2009
    Link to this post
    Hello Georgi,,

    thank you very much for pointing me to the replacement tool, I wasn't aware of this yet.

    regards, Mikael
  5. Georgi
    Georgi avatar
    3583 posts
    Registered:
    28 Oct 2016
    04 Mar 2009
    Link to this post
    Hello Mikael Kleinwort,

    No worries. Let me know if you have any questions about it.

    Best wishes,
    Georgi
    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.
Register for webinar
5 posts, 0 answered