Reputation: 7165
Almost solution I found was using javascript/jquery while on my part it should be Views in MVC. One reference is here
So I set up my css files in this way:
@{
ViewBag.Stylesheets = new string[] {
"global/style.css",
"global/links.css",
.
.
.
. 40 plus more css files...
};
And load them:
@foreach (string stylesheet in
ViewBag.Stylesheets is string[] ? ViewBag.Stylesheets : new string[] { @"style.css" })
{
<link href="@Url.ContentArea("~/css/" + stylesheet)" rel="stylesheet" />
}
All of these were inside views. I have 48 css files and I notice that IE9 loads only 37 css files. For now it is not possible to combine css codes in some number of files for certain reasons. So how can I load all of these css files in IE?
Upvotes: 0
Views: 572
Reputation: 1038730
Internet Explorer has a limit
of 31 CSS files per page. This limitation has been removed in IE 10.
So you have 2 possibilities if you need to support IE <= 9:
Upvotes: 3