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

Forums / General Discussions / CSS for Themes not loading (404)

CSS for Themes not loading (404)

10 posts, 0 answered
  1. Ryan Dailey
    Ryan Dailey avatar
    41 posts
    Registered:
    08 Mar 2010
    19 Sep 2011
    Link to this post
    I deployed my Sitefinity 4.2 website to IIS 6.  However, I noticed that the CSS was not loading.  I am receiving a 404 error for the CSS file.

    The page appears to be referencing the stylesheet correctly:

    <head><title>
        Home
    </title>
       
        <!-- No tags beyond this point -->
    <meta name="Generator" content="Sitefinity 4.2.1650.0 SE" /><link href="/Sitefinity/WebsiteTemplates/App_Themes/HealthChoice/global/ie7.css" type="text/css" rel="stylesheet" /><link href="/Sitefinity/WebsiteTemplates/App_Themes/HealthChoice/global/style.css" type="text/css" rel="stylesheet" /></head>

    How can I get the stylesheet to show?  Thanks.
  2. Svetoslav Petsov
    Svetoslav Petsov avatar
    456 posts
    Registered:
    24 Sep 2012
    19 Sep 2011
    Link to this post
    Hi Ryan Dailey,

     This is because of the names of the CSS files that you have put inside the "Global" folder. Sitefinity has strict mappings for names, so you should follow exactly this folder structure, when creating themes:
    http://www.sitefinity.com/documentation/designers-guide/website-templates-file-structure.aspx
    Inside the Global folder, you must have only "main.css" and "reset.css" files. Only they will be loaded automatically by Sitefinity. All .css files with different names should be placed inside the "CSS" folder.

    Greetings,
    Svetoslav Petsov
    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
  3. Ryan Dailey
    Ryan Dailey avatar
    41 posts
    Registered:
    08 Mar 2010
    19 Sep 2011
    Link to this post
    I renamed the stylesheet to main.css and it's still not showing up.  It showed up fine before I deployed it.  What's different in IIS 6?
  4. Svetoslav Petsov
    Svetoslav Petsov avatar
    456 posts
    Registered:
    24 Sep 2012
    20 Sep 2011
    Link to this post
    Hi Ryan Dailey,

     What kind of hosting do you use? Is there a chance that the .css files could have been lost during the upload of your project?
    Also, please try putting the your theme (or just the problematic files) in another folder outside App_Data and see if you can load them (try together with the theme and with a CSS widget to see if the problem comes from the theme or the files themselves). There are some problems with the App_Data folder, as it is a special ASP folder which requires some permissions and this may be the cause for the .css files not loading). Don't forget to keep the name main.css 

    Regards,
    Svetoslav Petsov
    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
  5. Juan Sola
    Juan Sola avatar
    28 posts
    Registered:
    08 Jan 2007
    22 Sep 2011
    Link to this post
    I am having the same issue under IIS6. I have since moved my App_Themes folder to the root of the website and hard coded the css link on the master page file, which now works.

    I have provided the AppPool Identity full access to the entire website folder and have completed all installation steps.

    I also had my original css file named style.css but have since changed to main.css with no luck.

    Any insight into why this is happening?
  6. Svetoslav Petsov
    Svetoslav Petsov avatar
    456 posts
    Registered:
    24 Sep 2012
    26 Sep 2011
    Link to this post
    Hi Ryan Dailey,

    As I said in the previous post, the App_Data folder is a special ASP.Net folder and has some unique permissions set on it, so to avoid problems, just place your themes outside App_Data.

    Kind regards,
    Svetoslav Petsov
    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
  7. Ryan Dailey
    Ryan Dailey avatar
    41 posts
    Registered:
    08 Mar 2010
    27 Sep 2011
    Link to this post
    I placed my Themes outside the App_Data folder and it seems to be working.
  8. Mike
    Mike avatar
    208 posts
    Registered:
    10 Dec 2007
    30 May 2012
    Link to this post
    I'm having the same issue.  The site, when deployed to IIS6, does not seem to pick up the mapping to the theme folders.  Given that Sitefinity has (for whatever reason) decided that the themes belong in a subfolder of app_data, how do I get this mapping fixed? 
  9. Richard
    Richard avatar
    103 posts
    Registered:
    04 Apr 2013
    08 Jul 2014
    Link to this post

    Yes, I'm getting the same problem now. I'd rather try to fix this so I keep doing the way Sitefinity lays it out. Is there a resolution for this?

    The problem I'm getting is i'm getting 404's for two css files. 

    reset.css

    Layout.css  

    The folder ONLY has these 2 css files and one cssLoadOrder.xml with a sub-directory Global. Whieh... is empty. 

  10. Stefani Tacheva
    Stefani Tacheva avatar
    718 posts
    Registered:
    21 Nov 2016
    10 Jul 2014
    Link to this post
    Hello,

    We have answered you in the support ticket you have opened. Once the problem is resolved you could share the solution with the community.

    Regards,
    Stefani Tacheva
    Telerik
     
    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 Sitefinity CMS Ideas&Feedback Portal and vote to affect the priority of the items
     
10 posts, 0 answered