I'm quite new to the world of ASP.NET and having some sort of problem in handling as per topics.
I'm currently using VS 2013 (commersial version) but found difficulty to catch up on these techniques for Minifying issues.I'm develop some practice through normal ASP.NET but not MVC type of Web Application Project.
- In "App_Start", I've created 'BundleConfig.cs',
-The Content of Test1.css and Test2.css I've been created,
-Then in my "global.asax"
-or,
Can anyone one else guide me on how to bring this above coding to work ?
I'm currently using VS 2013 (commersial version) but found difficulty to catch up on these techniques for Minifying issues.I'm develop some practice through normal ASP.NET but not MVC type of Web Application Project.
- In "App_Start", I've created 'BundleConfig.cs',
Code:
[indent]public class BundleConfig
{
public static void RegisterBundles(BundleCollection bundles)
{
bundles.Add(new ScriptBundle("~/Styles/css").Include("~/Styles/Test1.css",
"~/Styles/Test2.css")
);
BundleTable.EnableOptimizations = true;
}[/indent]
Code:
h1
{
text-decoration: underline;
}
h1
{
color : red;
}
-Then in my "global.asax"
Code:
[indent]protected void Application_Start(object sender, EventArgs e)
{
BundleConfig.RegisterBundles(BundleTable.Bundles);
}[/indent]
-In my 'default.aspx' markup view, neither of both belows are totally not working.
[indent]<head runat="server">
<title></title>
<link href='<%= System.Web.Optimization.Styles.Render("Styles/css") %>' rel="stylesheet" />
</head>
[/indent]
Code:
[indent]<head runat="server">
<title></title>
<%: System.Web.Optimization.Styles.Render("Styles/css") %>
</head>[/indent]
Can anyone one else guide me on how to bring this above coding to work ?