[wordpress插件] CC-MinifyCC缩小

wordpress 插件 文章 2020-03-19 14:50 466 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

The CC-Minify plugin optimizes your website’s CSS and JS files by combining, minifying, grouping and caching them to speed up your page’s load time.

CC-Minify插件通过组合,缩小,分组和缓存它们来优化您网站的CSS和JS文件,以加快页面的加载时间。

This plugin uses the Minify PHP library.

此插件使用 Minify PHP库。

Additionally using Apache with mod_rewrite (or other server supports URL rewriting) it can rewrite URL to simplify the CSS and JS paths, for example:

此外,将Apache与mod_rewrite结合使用(或其他服务器支持URL重写),它可以重写URL以简化CSS和JS路径,例如:

from: http://example.com/wp-content/cache/styles/all.css to: http://example.com/styles/all.css

从: http://example.com/wp-content/cache/styles/all.css 到: http://example.com/styles/all.css



from: http://example.com/wp-content/cache/scripts/head.js to: http://example.com/scripts/head.js

从: http://example.com/wp-content/cache/scripts/head.js 到: http://example.com/scripts/head.js



This plugin is compatible with Multisite WordPress installations.

此插件与多站点WordPress安装兼容。

Tips & Tricks

提示和技巧

You can check if a css and/or js files has been served from a cache by opening the page’s source code.

您可以通过打开页面的源代码来检查是否已从缓存中提供css和/或js文件。

If files are served from cache, you should see a comment with the date and time when it was last cached, for example:
    

如果文件是从缓存提供的,则应该看到带有最后缓存日期和时间的注释,例如:
    

<!-Minify @ 2016-11-07 12:34:56->

Requirements

要求

    1. Server supports URL rewriting: Apache with mod_rewrite, IIS 7.0+ permalink support or nginx.
    2. 服务器支持URL重写:Apache带有mod_rewrite,IIS 7.0+永久链接支持或nginx。

    3. Read/Write access to wp-content/cache directory.
    4. 读取/写入对wp-content / cache目录的访问。

    5. PHP interpreter version >= 5.3.
    6. PHP解释器版本> = 5.3。

安装步骤

From your WordPress Dashboard

从您的WordPress仪表板中

    1. Go to ‘Plugins > Add New’
    2. 转到“插件>添加新内容”

    3. Search for ‘CC-Minify’
    4. 搜索“ CC-缩小”

    5. Activate the plugin from the Plugin section on your WordPress Dashboard.
    6. 从WordPress仪表板上的“插件”部分激活插件。

    From WordPress.org

    来自WordPress.org

      1. Download ‘CC-Minify’.
      2. 下载“ CC-Minify”。

      3. Upload the ‘CC-Minify’ directory to your ‘/wp-content/plugins/’ directory using your favorite method (ftp, sftp, scp, etc…)
      4. 使用您喜欢的方法(ftp,sftp,scp等)将“ CC-Minify”目录上传到“ / wp-content / plugins /”目录中

      5. Activate the plugin from the Plugin section in your WordPress Dashboard.
      6. 从WordPress信息中心的“插件”部分激活插件。

      Once Activated

      一旦激活

        1. Visit the ‘Settings > Minify’ page, select your preferred options and save them.
        2. 访问“设置>缩小”页面,选择您喜欢的选项并保存。

        3. To properly rewrite URLs, add the rules listed in ‘Settings > Minify’ to the beginning of your .htaccess file.
        4. 要正确地重写URL,请将“设置>缩小”中列出的规则添加到 .htaccess 文件的开头。

        Multisite

        多站点

        The plugin can be activated and used for just about any use case.

        可以激活该插件并将其用于几乎所有用例。

          • Activate at the site level to load the plugin on that site only.
          • 在站点级别激活以仅在该站点上加载插件。

          • Activate at the network level for full integration with all sites in your network (this is the most common type of multisite installation).
          • 在网络级别激活以与网络中的所有站点完全集成(这是多站点安装的最常见类型)。

下载地址
https://downloads.wordpress.org/plugin/cc-minify.zip
-EOF-

AI助手支持GPT4.0