Title: CDNJS for WordPress
Author: Paul
Published: <strong>2012 年 12 月 17 日</strong>
Last modified: 2017 年 4 月 25 日

---

搜尋外掛

這個外掛**並未在最新的 3 個 WordPress 主要版本上進行測試**。開發者可能不再對這個
外掛進行維護或提供技術支援，並可能會與更新版本的 WordPress 產生使用上的相容性問題。

![](https://s.w.org/plugins/geopattern-icon/cdnjs.svg)

# CDNJS for WordPress

 由 [Paul](https://profiles.wordpress.org/paultgoodchild/) 開發

[下載](https://downloads.wordpress.org/plugin/cdnjs.1.3.3.zip)

 * [詳細資料](https://tw.wordpress.org/plugins/cdnjs/#description)
 * [使用者評論](https://tw.wordpress.org/plugins/cdnjs/#reviews)
 * [開發資訊](https://tw.wordpress.org/plugins/cdnjs/#developers)

 [技術支援](https://wordpress.org/support/plugin/cdnjs/)

## 外掛說明

#### What is CDNJS?

This is best described in [this article on Cloudflare.com](http://blog.cloudflare.com/cdnjs-the-fastest-javascript-repo-on-the-web).

CDNJS is a freely available CDN for common Javascript and CSS libraries.

This plugin simply lets you use them more easily on your WordPress site.

This plugin is produced and supported by [iControlWP: Multiple WordPress Management](http://icwp.io/6y).

## 常見問題集

  How can I install the plugin?

This plugin should install as any other WordPress.org respository plugin.

 1. Browse to Plugins -> Add Plugin
 2. Search: CDNJS
 3. Click Install
 4. Click to Activate.

Alternatively using FTP:

 1. Download the zip file using the download link to the right.
 2. Extract the contents of the file and locate the folder called ‘cdnjs’ containing
    the plugin files.
 3. Upload this whole folder to your ‘/wp-content/plugins/’ directory
 4. From the plugins page within WordPress locate the plugin ‘CDNJS’ and click Activate

A new menu item will appear on the left-hand side called ‘CDNJS’. Click this menu
and select ‘Includes’.

Select the includes you desire. Only select what you need.

  How does this affect the JQuery supplied with WordPress itself?

If you select the option, it will include the currently latest available JQuery 
and replace the one that comes with your WordPress distribution.

  Why would I use this plugin at all?

As just another little boost your website page-load performance. If your visistors
are using the CloudFlare/CDNJS files
 their pages should load quicker, and as more
and more people use the CDN, it’ll help everyone load their sites quicker!

  What has iControlWP got to do with Cloudflare and CDNJS?

Not a lot, but we like website optimizations and making things faster/better. We
saw this project on the Cloudflare blog
 and instantly wanted to use it on our sites.
What easier way than to make a plugin, and then we can share it too.

  The plugin doesn’t list the Javascript/CSS that I want?

Your webhosting either doesn’t support the file_get_contents() for URLs, or doesn’t
have json_decode function/library for PHP.

  The page for choosing the libraries loads very slow – why?

It’s pulling in the complete list of libraries available each time. It only does
this on this page, so don’t worry about
 this each time you load your site.

## 使用者評論

![](https://secure.gravatar.com/avatar/d65445c7932e77bf8d1ca0d3fd492f410bc97e16b1dee29b59b09c61a1d9fea1?
s=60&d=retro&r=g)

### 󠀁[Good but need enhancement](https://wordpress.org/support/topic/good-but-need-enhancement/)󠁿

 [John](https://profiles.wordpress.org/dpinc/) 2016 年 9 月 3 日

Provide fallback in case cdn failed and ability to choose version

![](https://secure.gravatar.com/avatar/911ab197e913962c3bec7e7150ec0f3ef84a1ac05933b31259360b2b144dfa76?
s=60&d=retro&r=g)

### 󠀁[Load Order](https://wordpress.org/support/topic/load-order-2/)󠁿

 [akincansenol](https://profiles.wordpress.org/akincansenol/) 2016 年 9 月 3 日

Cdnjs resources load before jquery so some library doesn’t work because jquery not
defined yet. I see there is alphabetical order but we need custom order to handle
this problem.

 [ 閱讀全部 9 則使用者評論 ](https://wordpress.org/support/plugin/cdnjs/reviews/)

## 參與者及開發者

以下人員參與了開源軟體〈CDNJS for WordPress〉的開發相關工作。

參與者

 *   [ Paul ](https://profiles.wordpress.org/paultgoodchild/)
 *   [ Dave Goodchild ](https://profiles.wordpress.org/dlgoodchild/)

[將〈CDNJS for WordPress〉外掛本地化為台灣繁體中文版](https://translate.wordpress.org/projects/wp-plugins/cdnjs)

### 對開發相關資訊感興趣？

任何人均可[瀏覽程式碼](https://plugins.trac.wordpress.org/browser/cdnjs/)、查看 
[SVN 存放庫](https://plugins.svn.wordpress.org/cdnjs/)，或透過 [RSS](https://plugins.trac.wordpress.org/log/cdnjs/?limit=100&mode=stop_on_copy&format=rss)
訂閱[開發記錄](https://plugins.trac.wordpress.org/log/cdnjs/)。

## 變更記錄

#### TODO

 * Improve the UI for search and filtering.

#### 1.3.3

 * UPDATE: Some code improvements, styling etc.
 * UPDATE: Compatibility with WordPress 4.7
 * UPDATE: Compatibility with PHP 7

#### 1.3.2

 * FIX: Various PHP warnings
 * UPDATE: Compatibility with WordPress 4.5

#### 1.3.1

 * UPDATE: Compatibility with WordPress 4.0

#### 1.3.0

 * IMPROVED: Query to CDNJS for library now uses their newer API system
 * FIX: Compatibility with WordPress 3.9+
 * FIX: Compatibility with PHP 5.4.0+

#### 1.2.b

 * FIX: foreach() warning when there have not yet anything selected for include

#### 1.2.a

 * Now uses the packages.json list for all available packages.
 * Fixes a few errors.

#### 1.1.a

 * Fixes a few errors.

#### 1.0

 * First public release
 * Allows you to select to include a short list of all available CSS and Javascript
   available from CDNJS.com

## 中繼資料

 *  版本 **1.3.3**
 *  最後更新 **9 年前**
 *  啟用安裝數 **10+**
 *  WordPress 版本需求 ** 3.5.0 或更新版本 **
 *  已測試相容的 WordPress 版本 **4.8.28**
 *  語言
 * [English (US)](https://wordpress.org/plugins/cdnjs/)
 * 標籤
 * [cdn](https://tw.wordpress.org/plugins/tags/cdn/)[CDNJS](https://tw.wordpress.org/plugins/tags/cdnjs/)
   [cloudflare](https://tw.wordpress.org/plugins/tags/cloudflare/)[css](https://tw.wordpress.org/plugins/tags/css/)
   [JS](https://tw.wordpress.org/plugins/tags/js/)
 *  [進階檢視](https://tw.wordpress.org/plugins/cdnjs/advanced/)

## 評分

 3.9 星，滿分為 5 星

 *  [  5 個 5 星使用者評論     ](https://wordpress.org/support/plugin/cdnjs/reviews/?filter=5)
 *  [  1 個 4 星使用者評論     ](https://wordpress.org/support/plugin/cdnjs/reviews/?filter=4)
 *  [  1 個 3 星使用者評論     ](https://wordpress.org/support/plugin/cdnjs/reviews/?filter=3)
 *  [  1 個 2 星使用者評論     ](https://wordpress.org/support/plugin/cdnjs/reviews/?filter=2)
 *  [  1 個 1 星使用者評論     ](https://wordpress.org/support/plugin/cdnjs/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/cdnjs/reviews/#new-post)

[查看全部使用者評論](https://wordpress.org/support/plugin/cdnjs/reviews/)

## 參與者

 *   [ Paul ](https://profiles.wordpress.org/paultgoodchild/)
 *   [ Dave Goodchild ](https://profiles.wordpress.org/dlgoodchild/)

## 技術支援

使用者可在技術支援論壇提出意見反應或使用問題。

 [檢視技術支援論壇](https://wordpress.org/support/plugin/cdnjs/)

## 贊助

想要支援這個外掛的發展嗎？

 [ 贊助這個外掛 ](https://www.icontrolwp.com/)