Adding Custom Banner Images
This section explains how to add custom banner images to Presence Builder's image library, and make them available for selection in the editor.
Suppose, you have an image file with the name
jungle.jpg, and you want to add it to the editor. Do the following:
- Resize the image to 960 pixels in width and 250 pixels in height. Convert the image to PNG format, and save it as
- Create a copy of
header.png, resize it to 200 pixels in width, and 57 pixels in height. Save it as
- Connect over SSH to the hosting server.
- Locate the directory
/sb/htdocs/headers/, and create a subdirectory with the banner name. For example,
- Upload the
preview.pngfiles that you prepared to the directory
- Locate the directory
/sb/resources/. It should contain the file
If the file is missing, create it and insert the following lines into it:
<?xml version="1.0" encoding="utf-8"?>
If the file is present, add the following <header> node to it:
- Add keywords for the image.
Keywords are used for the following purposes:
Binding of images to website topics. When a new site is created based on a website topic, the editor searches for banner images that may be relevant to the topic, and adds one of them to the generated website. It also uses the relevant banners in generated design templates, which users can preview and select in the editor > Design tab > Templates. The relevance is determined by matching keywords in the website topic's meta data and in the
headers.lngfile containing descriptions of all banner images in the form of keywords.
- Enabling users to find images by keywords in the banner selection menu.
To add keywords, do the following:
- Open for editing the file
- Add a string in the following format:
<header_id> = "<keyword_1>,<keyword_2>,<keyword_3>"
<header_id>is the image ID that you specified in step 6, but with certain transformations: all uppercase letters must be changed to lower case, hyphens must be removed, the next symbol following a hyphen must be changed to upper case.
Jungle_01-eXample, then it must be changed to
my-super-banner, then it should be transformed to
my_super_banner, then it should be transformed to
<keyword>is a human-readable word that describes the image or identifies items on the picture.
You can use several keywords separated by commas. White spaces can be used only if they are part of a descriptive phrase or a combination of words.
jungle01 = "jungle,tropics,green,nature,family travel"
- Save the file.
- Binding of images to website topics. When a new site is created based on a website topic, the editor searches for banner images that may be relevant to the topic, and adds one of them to the generated website. It also uses the relevant banners in generated design templates, which users can preview and select in the editor > Design tab > Templates. The relevance is determined by matching keywords in the website topic's meta data and in the
- Issue the following command:
/usr/local/psa/bin/sw-engine-pleskrun /usr/local/sb/utils/updateResources.php header
Now you can go to the editor and open the list of banner images. The newly added image should be at the end of the list.
Leave your feedback on this topic here
If you have questions or need support, please visit the Plesk forum or contact your hosting provider.
The comments below are for feedback on the documentation only. No timely answers or help will be provided.