More in this section

Forums / General Discussions / CSS link in build-in templates

CSS link in build-in templates

4 posts, 0 answered
  1. Pat
    Pat avatar
    20 posts
    Registered:
    18 Feb 2003
    03 Mar 2011
    Link to this post
    Hi there,
    I linked a css file to a template with the css widget from the toolbox.
    There is a selector to choose a css file within your site. But the selector returns and stores the absolute path to the file and not a relative one as expected. So if you are not aware of this behaviour, once your site moves to the final destination, all css references are broken. Is that by design? Do I have to manually strip the path to relative?

    Regards

    Patrick
  2. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    28 Aug 2017
    03 Mar 2011
    Link to this post
    Hi Pat,

    Thank you for contacting Telerik Support.

    This has been fixed for the Service Pack - now we're using application relative path, so there should be no problem. Please try upgrading to SP1 and inform me if this has resolved the problem.

    All the best,
    Boyan Barnev
    the Telerik team
  3. John
    John avatar
    22 posts
    Registered:
    14 Jan 2011
    09 Sep 2011
    Link to this post
    Hi,

    I'm using SF 4.2 and this issue is still there... (absolute path).

    On the other hand, any suggestions to link a CSS stored in the theme's folder in a build-in template directly ?
    The file is in App_Data/Sitefinity/WebsiteTemplates/Master/App_Themes/MYTHEME/STYLES.CSS.
    The App_Data is forbidden to browse, so the file is unavailable to use it in a page.
    SF doesn't resolve the address like a ResourceLinks control used in code behind do it.

    I don't want to use the theme's GLOBAL folder because it loads the css file in all pages. I need it just in one template.
    I don't want to use just another theme with a GLOBAL folder just for ONE css file.

    Is just this possible ?

    Thanks,

    John.
  4. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    28 Aug 2017
    14 Sep 2011
    Link to this post
    Hi John,

    Please excuse for the inconvenience, indeed the error still reproduces, we are working on fixing it. In the meantime, can you please try placing that particular CSS outside of the App_Data folder, and referencing it with the CSS widget - it should be applied without any problems.

    Regards,
    Boyan Barnev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
4 posts, 0 answered