plugin-icon

Replace Asset Source

Replace plugins or themes asset source with your own desired source. Not design for auto local host asset file. But you can use for it too.
Puanlar
5
Son güncellenme
November 2, 2022
Sürüm
1.3.1
Aktif kurulumlar
60
Replace Asset Source

Replace any plugin or theme asset source with your own desired source. Main purpose is to help WordPress users to change the slow third party scripts or styles which using by some plugins but slow load speed in certain countries.

Usually, you could use some coding skills to find the original enqueue method from the target plugin, then dequeue it, and enqueue your own version of asset file. But you need to take care and follow the same way how the original plugin enqueued and the dependency plus version. Otherwise, you might encounter some unexpected issues.

With the help of this plugin, you can easily replace the asset source file without coding skills.

This plugin is not meant to auto local host the third party asset file, but you could use for it too. Upload your own local version of asset file in a better and secured folder (maybe from your theme folder), get the public accessible url, use it on the plugin setting page. Just try it out and have fun.

How It Works

Once a new replacement set, this plugin will do a match on all queued asset styles and scripts source. If found the matching source, it will replaces target source URL with your replacement URL.

This plugin is not going to dequeue the target asset and enqueue your replacement asset. Issue might be happened if the new enqueue not follow the original plugin or theme like missing dependency or version incorrect etc.

If the target asset url not using the standard WordPress enqueue script method by the developer, the replacement will not works.

Use Case

There is a block in Malaysia since end of September 2021, which not allowed all local ISP network to access maxcdn.bootstrapcdn.com.

If there is a plugin in your site using the asset file hosted on maxcdn.bootstrapcdn.com, the visitor from Malaysia will encounter super slow loading issue.

With the help of this plugin, you can easily replace this asset file url to maybe cdnjs.cloudflare.com without disturbing the functionality of the original plugin.

Tutorial for this use case:

Solve maxcdn bootstrapcdn problem in Malaysia

ÜcretsizCreator paketinde
Yükleme işlemini tamamlayarak, WordPress.com'un Hizmet Şartları ile Üçüncü Taraf Eklenti Şartlarını kabul etmiş olursunuz.
Aktif kurulumlar
60
Test edilen son sürüm
6.1.7
Bu eklenti, WordPress tarafından barındırılan kurulumunuzda kullanılmak üzere indirilebilir.