【问题标题】:not able to rewrite the js and css file using apache httpd无法使用 apache httpd 重写 js 和 css 文件
【发布时间】:2015-01-12 10:22:23
【问题描述】:

我们正在使用 RewriteRule ^.+/(js|css)(.+).([0-9]+).(js|css)$ $1$2.$4 来重写我的文件。 文件名格式为aTest.123456.js或aTest.123563.css。 上面提到的文件名在我的 jsp 页面中使用,而我的物理文件为 aTest.js 或 aTest.css。

请建议我穿在哪里。

【问题讨论】:

    标签: apache


    【解决方案1】:

    我们已经重写了上面的规则,如下所示。

        RewriteEngine On
    
        RewriteRule ^/InstaLife/(javaScript|css)/(.+)\.([0-9]*)\.(js|css)$ /InstaLife/$1/$2.$4 [R]
        RewriteRule ^/InstaLife/css/(PopUP|PopU)/(.+)\.([0-9]*)\.(js|css)$ /InstaLife/css/$1/$2.$4 [R]
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2019-12-13
      • 2014-01-04
      • 2014-06-06
      • 1970-01-01
      • 2011-10-24
      • 2016-12-07
      • 2013-11-18
      • 1970-01-01
      相关资源
      最近更新 更多