How to integrate UCDN with B2Evolution?

UCDN
2018-10-18 15:54

(*Disclaimer: Please be advised that the following instructions may have undergone some changes due to the third-party software and plugins updates.)

b2evolution.net

You only need to edit a single file in order to set the path variables to point to the CDN location:

Open blogs/conf/_advanced.php Add the following code on top of the page:

$cdnurl = ‘http://ucdn.your-domain.net/’;

So that first line of code looks like this:

<?php  $cdnurl = ‘http://ucdn.your-domain.net/’;

Find the following line:

$rsc_url = $baseurl.$rsc_subdir;

Replace it with:

$rsc_url = $cdnurl.$rsc_subdir;

Find the following line:

$skins_url = $baseurl.$skins_subdir;

Replace it with:

$skins_url = $cdnurl.$skins_subdir;

Find the following line:

$media_url = $baseurl.$media_subdir;

Replace it with:

$media_url = $cdnurl.$media_subdir;

Note:
"ucdn.your-domain.net" needs to be replaced with the proper CDN temp URL or, if you have a custom URL, the proper custom URL. You can check if your application is using the CDN by reloading it in your browser and viewing the source code of the page.

Tags: B2Evolution