js、css动态压缩页面代码

1、js、css动态压缩页面代码

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="index.aspx.cs" Inherits="index" %>

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>js、css动态压缩</title>
    <%--<script type="text/javascript" src="../js/jquery-1.4.4.js"></script>
    <script type="text/javascript" src="../js/jquery-1.9.0.min.js"></script>
    <script type="text/javascript" src="../js/jquery.cookie.js"></script>
    <script type="text/javascript" src="../js/common.js"></script>
    <script type="text/javascript" src="../js/track.js"></script>--%>
    <%= 

         SquishIt.Framework.Bundle.Css()
        .Add("~/content/css/common.css")
        .ForceRelease()
        .Render("~/css/common.css") 
    %>

    <%=   
         SquishIt.Framework.Bundle.JavaScript()
        .Add("~/content/js/jquery-1.4.4.js")
        .Add("~/content/js/jquery-1.9.0.min.js")
        .Add("~/content/js/jquery.cookie.js")
        .Add("~/content/js/common.js")
        .Add("~/content/js/track.js")
        .ForceRelease()
        //.Render("~/js/common_#.js")
        .Render("~/js/lib.js")
    %>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <span id="pc_1" style="text-align: center;"></span>
            <span id="pcm_1"></span>
        </div>
        <div style="margin: 0px auto; width: 100%; font-size: 16px; color: #FF0606; font-weight: bold; text-align: center; background-color: #FFFFE5; background-position: 15px -888px; border: 1px solid #FFCC7F; border-width: 1px 0px; padding: 10px 0;">
            网站测试中,暂不接受正式订单!
        </div>
    </form>
</body>
</html>


2、动态压缩需要用到的dll

js、css动态压缩页面代码_第1张图片

3、动态压缩后

js、css动态压缩页面代码_第2张图片


你可能感兴趣的:(js、css动态压缩页面代码)