This applies to our legacy Minimus\Medius\ Maximus hosting plans only.
Most common issues with templates that are based on the TimThumb plugin are path related. The application vault installation files for Wordpress are placed in a webspace/siteapps directory, more on how to locate these can be found at: https://help.blacknight.com/entries/22941728-location-of-files-for-applications-installed-through-application-vault.
TimThumb is looking for the images in the root directory for the domain and is not being redirected to the actual App Vault installation location and therefore it does not display the images.
This can be easily rectified by adjusting paths in the timthumb.php file, here is an example of the lines that needs modifying and what the correct paths should be:
- $WEBSPACE needs to be replaced with the actual webspace ID, this can be found under All Domains > domain name > WebSite Configuration
- $SITEAPPID needs to be replaced with the ID of the application, it is found to the left of the installation name in the Application Vault. That is under: Web Hosting > Application Vault > application type > application name.
define('LOCAL_FILE_BASE_DIRECTORY', '/usr/local/pem/vhosts/$WEBSPACE/webspace/siteapps/$SITEAPPID/htdocs');
$_SERVER['DOCUMENT_ROOT'] = '/usr/local/pem/vhosts/$WEBSPACE/webspace/siteapps/$SITEAPPID/htdocs';
Note:
If the define entry is not present you will need to add it, look for a commented section like below and add it afterwards.
/** * Additional Parameters: * LOCAL_FILE_BASE_DIRECTORY = Override the DOCUMENT_ROOT. This is best used in timthumb-config.php */
It will become this - ensure you amend the $WEBSPACE and $SITEAPPID values as suggested above:
/** * Additional Parameters: * LOCAL_FILE_BASE_DIRECTORY = Override the DOCUMENT_ROOT. This is best used in timthumb-config.php */
// Set local directory.
define('LOCAL_FILE_BASE_DIRECTORY', '/usr/local/pem/vhosts/$WEBSPACE/webspace/siteapps/$SITEAPPID/htdocs');
// Force 'Document Root' to reflect Site Application install.
$_SERVER['DOCUMENT_ROOT'] = '/usr/local/pem/vhosts/$WEBSPACE/webspace/siteapps/$SITEAPPID/htdocs';
Important:
You will need to ensure you have the most recent version of TimThumb available to protect against security vulnerabilities. Additionally for each time you update the timthumb.php file you will need to make sure you follow the process above again as your changes would be removed between files.
Comments
0 comments
Article is closed for comments.