Presence Builder Standalone on servers managed by control panel software other than
Parallels Operations Automation and Parallels Plesk.
Feedback
If you have found an error in this guide, or if you have suggestions or ideas on how to
improve this guide, please send your feedback using the online form at
http://www.parallels.com/en/support/usersdoc/. Please include in your report the
guide’s title, chapter and section titles, and the fragment of text in which you have
found an error.
Parallels Presence Builder Standalone is a software suite for hosting providers. It
C H A P T E R 2
About Parallels Presence Builder
Standalone
includes the following components:
Presence Builder - website design and promotion tool.
API for integration into a hosting company’s infrastructure.
This solution is ideal for hosting service providers who have their own shared hosting
control panel and a billing system, and who want to offer Presence Builder to their
customers.
Presence Builder can operate in the trial mode. When the trial mode is properly
configured, prospective customers can access the editor, create websites, and publish
them after they sign up to hosting services. To learn more about the trial mode, see the
chapter Configuring the Trial Mode (on page 51).
You can install the core components of the system on the same server on which you
In this chapter:
Requirements for the Core Server ..................................................................... 7
Requirements for Publishing Servers ................................................................ 8
Supported Web Browsers.................................................................................. 8
C H A P T E R 3
Preparing for Installation
plan to host websites, or have one dedicated server for running the system (let’s call it
the core server) and publish websites on separate hosting servers. The following figure
illustrates a typical deployment scheme and the interaction of the components.
Before installing, make sure that the following requirements for the core server (on
page 7) and publishing servers (on page 8) are met.
Preparing for Installation 7
Requirements for the Core Server
Minimum Hardware Requirements
Intel or AMD CPU, 800 MHz.
500 megabytes of free disk space for installation of the core components, plus at
least 300 kilobytes for each hosted site.
8 gigabytes of RAM.
Software Requirements and Prerequisites
Parallels Presence Builder Standalone can be installed on the following operating
systems:
CentOS 5.10, 6.5 (32-bit and 64-bit).
Debian 6.0, 7.0 (32-bit and 64-bit).
The following software components, which are not included in the distribution package,
must be additionally installed:
Apache web server (apache2 package).
After installing Apache on CentOS systems, make sure that the following directive
is not present in the Apache configuration file /etc/httpd/conf/httpd.conf:
Alias /error/ “/var/www/error/”.
If it is present, comment it out and restart the web server.
MySQL Server version 5.0 or later.
Important: Make sure that the old_passwords value in the MySQL configuration
file is set to “0” (“off”). You can also check the current value of this parameter in the
database by issuing the following SQL query:
~# mysql -u<MYSQL_USER> -p<MYSQL_PASSWORD> -e”show variables
like ‘old_passwords’”
mod_fcgid.
This is available from the Debian 6 repositories (called libapache2-mod-fcgid), but if
you want to install on CentOS, you will need to obtain it from other third-party
repositories.
Important: On CentOS systems, SELinux must be disabled.
You can check whether SELinux is disabled by issuing the command
/usr/sbin/getenforce. If it is enabled, then do the following to switch it off:
1. Open the file /etc/selinux/config in a text editor and locate the
line SELINUX=<value>.
2. Change it to SELINUX=disabled.
8 Preparing for Installation
3. If you cannot find this file, open the file /boot/grub/grub.conf in a
text editor and add the parameter selinux=0 to the Grub Boot Loader:
5. If you do not want to restart, issue the command setenforce 0.
Note: The default values of the PHP settings memory_limit and
max_execution_time allow comfortable working with sites that have fewer than 500
pages. For this reason, the maximum number of pages that a site can have is set to
500 by default. If you want to support sites with a greater number of pages, configure
the PHP settings memory_limit and max_execution_time accordingly, and set a
greater value in the file /usr/local/sb/config, in the line maxPagesNumber =
500.
Requirements for Publishing Servers
Regardless of whether you plan to host customers’ sites on the same core server or
separate servers, ensure that the following additional requirements are met:
The servers are resolvable on the Internet: DNS settings are properly configured.
PHP version 5.2 or later is installed.
PHP supports multibyte string functions (mbstring extension).
In php.ini, the following directive is set: default_charset = “UTF-8”
Supported Web Browsers
Parallels Presence Builder Standalone supports the following browsers:
Internet Explorer 10 and 11.
Mozilla Firefox 19 or later.
Safari 6 for Mac.
Google Chrome 25 or later.
This chapter describes how to deploy Parallels Presence Builder Standalone.
In this chapter:
Installing on CentOS ......................................................................................... 10
Installing on Debian ........................................................................................... 11
After installation is finished, set the administrator’s password and install a license key
as described in Setting the Administrator’s Password and Installing a License Key (on
page 13).
If you want to make sure that the installation completed successfully, visit the editor in
the trial mode and create a trial site by accessing a URL very similar to this:
http://sitebuilder.<host name>/Try. You can find out the exact host name
and IP address by issuing the command apachectl -S.
Additionally, to ensure that the Presence Builder Standalone installation is accessible
by the domain name sitebuilder.<host name>, check and correct the DNS zone settings.
Important: If you plan to host websites on separate servers, make sure that these
servers are properly resolved from the core server and are accessible over HTTP and
FTP. You might need to manually configure DNS zones to ensure that the publishing
servers are resolved.
The following instructions describe how to install Parallels Presence Builder
Standalone by using the APT tools on Debian.
To install Parallels Presence Builder Standalone on Debian 6.0:
1. Add the following lines to the file /etc/apt/sources.list:
On 32-bit operating systems:
deb http://download1.parallels.com/WPB/Standalone/12.0/distdeb-Debian-6.0-i386 /
deb
http://download1.parallels.com/WPB/Standalone/12.0/thirdparty
-deb-Debian-6.0-i386 /
On 64-bit operating systems:
deb http://download1.parallels.com/WPB/Standalone/12.0/distdeb-Debian-6.0-x86_64 /
deb
http://download1.parallels.com/WPB/Standalone/12.0/thirdparty
-deb-Debian-6.0-x86_64 /
2. Issue the following command:
# apt-get update
3. Issue the following command:
# apt-get install wpb
After installation is finished, set the administrator’s password and install a license key
as described in Setting the Administrator’s Password and Installing a License Key (on
page 13).
If you want to make sure that the installation completed successfully, visit the editor in
the trial mode and create a trial site by accessing a URL very similar to this:
http://sitebuilder.<host name>/Try. You can find out the exact host name
and IP address by issuing the command apachectl -S.
Additionally, to ensure that the Presence Builder Standalone installation is accessible
by the domain name sitebuilder.<host name>, check and correct the DNS zone settings.
Important: If you plan to host websites on separate servers, make sure that these
servers are properly resolved from the core server and are accessible over HTTP and
FTP. You might need to manually configure DNS zones to ensure that the publishing
servers are resolved.
Installation has finished successfully, but Parallels Presence Builder Standalone does
not start. The following error message can be seen in /var/log/httpd/error.log:
During installation, the following error message is shown in the console:
[ERROR] Unable to connect to database. System message:
SQLSTATE[HY000] [2000] mysqlnd cannot connect to MySQL 4.1+
using the old insecure authentication. Please use an
administration tool to reset your password with the command SET
PASSWORD = PASSWORD(‘your_existing_password’). This will store a
new, and more secure, hash value in mysql.user. If this user is
used in other scripts executed by PHP 5.2 or earlier you might
need to remove the old-passwords flag from your my.cnf file
Resolution
Before installing Presence Builder, verify that the old_passwords option is switched
off in the MySQL configuration file. You can use the following command to verify the
value set for this option:
~# mysql -u<MYSQL_USER> -p<MYSQL_PASSWORD> -e”show variables
like ‘old_passwords’”
To switch off this option, add the line “old_passwords=0” into the file /etc/my.cnf,
section [mysqld].
Restart mysqld to apply the new settings:
~# /etc/init.d/mysqld restart
If, after restarting MySQL, you cannot access the editor in the trial mode (at
http://sitebuilder.<Presence Builder host name>/Try), and an error
message is shown in the browser, then you need to run the post-install configuration:
Setting the Administrator’s Password and
Installing a License Key
Before you can start using Presence Builder, you need to do the following:
Set the administrator’s password. There is only one administrator account. The
username is admin, and it cannot be changed.
Install a license key. To obtain a license key for the product, contact your vendor or
Parallels sales representatives. For contact information, refer to
www.parallels.com/contact.
To install a license key:
1. Set the administrator’s password by issuing the following command:
4. When prompted for a username and a password, provide the username
admin and the password that you specified in step 1.
5. Click Upload Key.
6. Browse to the license key file and click OK.
After the license key is uploaded, you can integrate Presence Builder with your control
panel or billing software by means of the API. For information about using the API,
refer to the chapters Integrating Parallels Presence Builder Standalone with Your Hosting Software (on page 18) and Appendix A. API Reference: Methods, Operations, and Resources
(on page 89).
You can also set Presence Builder to notify you when the number of published
websites allowed by your license has reached 90 percent. To do this:
1. On the Presence Builder server, open the configuration file
/usr/local/sb/config.
2. Add the following line after the line [general]:
admin_email = <your e-mail address>
3. Save the file.
Notices will be sent once a week.
To verify that the installation has been successfully completed, you can log in to the
editor in the trial mode by visiting http://sitebuilder.<host_name>/Try.
This chapter describes how to upgrade to Parallels Presence Builder 11 Standalone
In this chapter:
Upgrading on CentOS ....................................................................................... 16
Upgrading on Debian ........................................................................................ 17
Upgrading to Parallels Presence Builder
12 Standalone from Previous Versions
from the previous versions, 10.3, 10.4, 11.0, and 11.5.
What happens during an upgrade:
The product packages that are installed in the system are upgraded by using the
native means of package managers (apt or yum).
The product’s database and websites are upgraded to match the new product
version; however, all website content remains intact.
The contents of the configuration file /usr/local/sb/config are overwritten.
This means that all customizations made by editing the configuration file are
discarded.
16 Upgrading to Parallels Presence Builder 12 Standalone from Previous Versions
Upgrading on CentOS
The following instructions describe how to upgrade Parallels Presence Builder
Standalone by using the yum software management tool on CentOS 5.x-6.x or later.
To upgrade Parallels Presence Builder Standalone on CentOS, do the
following:
1. In /etc/yum.repos.d/, open the pa4wp.repo file for editing.
2. In the baseurl values specified under the sections titled
[sitebuilder-dist] and [sitebuilder-third], replace the old
addresses of the product repository with the following new addresses.
If you want to make sure that the upgrade has completed successfully, visit
http://sitebuilder.<host_name>/Try.
Upgrading to Parallels Presence Builder 12 Standalone from Previous Versions 17
Upgrading on Debian
The following instructions describe how to upgrade Parallels Presence Builder
Standalone by using the APT tools on Debian.
To upgrade Parallels Presence Builder Standalone on Debian 6.0:
1. Edit the file /etc/apt/sources.list to point the package manager to the
new repositories:
On 32-bit operating systems:
deb http://download1.parallels.com/WPB/Standalone/12.0/distdeb-Debian-6.0-i386 /
deb
http://download1.parallels.com/WPB/Standalone/12.0/thirdparty
-deb-Debian-6.0-i386 /
On 64-bit operating systems:
deb http://download1.parallels.com/WPB/Standalone/12.0/distdeb-Debian-6.0-x86_64 /
deb
http://download1.parallels.com/WPB/Standalone/12.0/thirdparty
-deb-Debian-6.0-x86_64 /
2. Issue the following command:
# apt-get update
3. Issue the following command:
# apt-get install wpb
If you want to make sure that the upgrade has completed successfully, visit
http://sitebuilder.<host_name>/Try.
Troubleshooting Upgrade Issues
Issue
On Debian Linux, upgrade of Presence Builder may fail with a “fatal error” message.
This could happen if some services required by Presence Builder, such as MySQL,
were not running when the upgrade was attempted.
Resolution
Start the MySQL database server and run the upgrade process again. Alternatively,
you can resume the upgrade by issuing the command dpkg—configure wpb-core.
This chapter provides general information about how you can integrate Parallels
C H A P T E R 6
Integrating Parallels Presence Builder
Standalone with Your Hosting Software
Presence Builder Standalone with your existing hosting software.
If your hosting software uses service plans, and the customer’s control panel
functionality is governed by plan options, you can customize the plans to include
access to the editor as an option. For information about adding custom plan options to
your hosting software, please consult the relevant documentation.
If your hosting software does not use service plans, or if you want to provide all hosting
customers with access to the editor regardless of the plans, then you need to do the
following:
1. Prepare scripts that will perform the necessary operations in the editor over the
API. The scripts will create sites in Presence Builder and redirect the user’s
browser to the editor.
2. Add a button leading to Presence Builder to the customers’ control panel area. The
button could be labeled, for example, Launch Presence Builder, or its caption could be
changed from Create Site to Edit Site, depending on whether a site for a given user
account or domain name is already present in Presence Builder.
When a user clicks Create Site, a new site should be created in Presence Builder
and the user’s browser should be redirected to the site creation wizard.
When a user clicks Edit Site, the control panel or a custom integration script must
redirect the user’s browser to the editor window containing the user’s site, ready
for editing.
After successful integration, your hosting customers will be able to access the
Presence Builder editor, create and edit sites, and publish them to their webspaces
over FTP.
Contents of this chapter:
Checking If Your Hosting Platform Is Compatible with Presence Builder. This section
describes how to check whether your hosting platform meets the hosting
requirements for publishing sites created with Presence Builder.
Providing Site Owners with Access to the Editor. This section describes how to
implement scripts for the Create Site and Edit Site buttons.
Deleting Sites from Presence Builder. This section describes how to implement
removal of sites from Presence Builder by means of the API.
Integrating Parallels Presence Builder Standalone with Your Hosting Software 19
In this chapter:
Checking if Your Hosting Platform Is Compatible with Presence Builder ........... 20
Providing Site Owners with Access to the Editor ............................................... 20
Deleting Sites from Presence Builder ................................................................ 26
20 Integrating Parallels Presence Builder Standalone with Your Hosting Software
Checking if Your Hosting Platform Is
Next in this section:
Initializing the API Library .................................................................................. 21
Adding the Create Site Button ........................................................................... 21
Adding the Edit Site Button ................................................................................ 24
Compatible with Presence Builder
Before you start preparing for the integration of Presence Builder with your hosting
platform, make sure that the latter meets Presence Builder’s hosting requirements. You
can do this by using a special script called check.php, which is shipped with
Presence Builder installations.
To check whether your hosting platform meets the hosting requirements
of Presence Builder:
1. Set up a web hosting account on your hosting platform. For example,
let’s assume that the hosting account will be associated with the
domain name example.com.
2. On the server where Presence Builder is installed, go to the directory
/usr/local/sb/resources/publish/.
3. Copy the script check.php from that directory to the hosting account’s
document root to make that script accessible by HTTP.
4. Using a web browser, visit http://example.com/check.php.
The script will show a report on the availability of the necessary hosting features.
Providing Site Owners with Access to the
Editor
To provide domain administrators (or site owners) with access to the Presence Builder
editor and enable them to create and edit websites, you need to add custom buttons or
hyperlinks labeled Create Site and Edit Site to the appropriate locations of your hosting
control panel. These locations might be a user’s home page, account profile, or
account dashboard page - whatever is present in your system. To learn how to add
custom buttons, consult the documentation for your hosting software.
Integrating Parallels Presence Builder Standalone with Your Hosting Software 21
Initializing the API Library
For integration purposes, we suggest that you use a library of PHP scripts that interact
with Presence Builder’s API. The library is shipped with Presence Builder. It is located
in the directory /usr/local/sb/utils/api-php/src.
To use the API library in your scripts, you need to do the following:
1. Ensure that PHP 5.2.x or later and the cURL PHP extension are installed on the
server where you will run scripts.
2. Take the scripts from the server where Presence Builder is installed - from
/usr/local/sb/utils/api-php/src, and copy them to the server where your
hosting platform is running.
3. In your PHP script (let’s call it create_site.php for illustration purposes) insert
the following lines:
<?php
require_once ‘/<path to the API library>/src/WpbApi.php’;
$config = array(
<path to the API library> is the directory to which you have copied the library in step
1.
<your Presence Builder host name> - the server where Presence Builder is
installed.
<Presence Builder password> - the password to your Presence Builder installation
that you specified after installing Presence Builder. This is described in the section
Setting the Administrator’s Password and Installing a License Key (on page 13).
For a complete list of operations that you can perform by means of the API, see
Appendix A. API Reference: Methods, Operations, and Resources (on page 89).
Adding the Create Site Button
The Create Site button must invoke a script written in PHP for example, which will create
a site in Presence Builder by means of the RestAPI HTTP requests. For details on
methods and parameters that can be used in an HTTP request, refer to the chapter API
Reference: Methods, Operations, and Resources, section Creating a Site (see page 98).
22 Integrating Parallels Presence Builder Standalone with Your Hosting Software
To create a site, you need to do the following:
Step 1. Connect the API library as described in the section Initializing the API Library (on
page 21).
Step 2. Prepare data that should be passed to Presence Builder for creating a new site.
The data must be presented in an array, as in the following example.
Integrating Parallels Presence Builder Standalone with Your Hosting Software 23
// Here you need to add a code that will save $siteUuid somewhere in your hosting
platform. This site ID is needed for further access to the website editor
// Generate an authorization token for the website
siteUuid - is a unique site ID.
localeCode - is the parameter that specifies the language that should be set for
the user interface when the user (site owner) logs in to the editor. The following
languages are supported:
en_US - American English
en_GB - British English
de_DE - German
es_ES - Spanish
fr_FR - French
it_IT - Italian
ja_JP - Japanese
nl_NL - Dutch
pl_PL - Polish
pt_BR - Brazilian Portuguese
ru_RU - Russian
zh_CN - simplified Chinese
zh_TW - traditional Chinese
sessionLifeTime - is the parameter that specifies (in seconds) the period of
inactivity for a user’s session in the editor. When this period elapses, the security
token expires and the user needs to log in again.
token - is the security token for redirecting a user’s browser to the editor.
wpbUrl - is the host name of the server where Presence Builder is installed.
24 Integrating Parallels Presence Builder Standalone with Your Hosting Software
To learn more about these parameters, refer to the section Generating a Security Token for
Accessing a Site (on page 102).
This script sample creates a website and returns a unique site identifier (UUID) for the
newly created site. It is important that you save this site ID for future reference because
you will need to specify that ID when retrieving information about a site, selecting a site
for editing, changing site properties, or deleting a site. Therefore, you need to write a
script that will save the received site ID to a file or a database.
Based on the site ID, the script must generate a security token for access to the editor,
and then redirect the user’s browser to the editor. A new security token must be
generated each time a site is opened for editing.
Adding the Edit Site Button
To add the Edit Site button, read the documentation for your hosting software. The Edit
Site button must contain a reference to a script written in PHP for example, which will
do the following:
1. Connect the API library as described in the section Initializing the API Library (on page
21).
2. Check in the database whether there is a site ID for a given domain name or a user
account.
3. Retrieve a site ID for a selected domain name or user account.
4. Generate a security token for that site ID through the API library. Note that the
security token is required to properly redirect the browser to the editor. A new
security token must be generated each time a site is opened for editing.
5. Redirect the user’s browser to the editor window.
The following sample script creates a security token for the retrieved site ID.
$siteUuid; //This variable contains the retrieved site ID
// Generate an authorization token for the website
$params = array(
Integrating Parallels Presence Builder Standalone with Your Hosting Software 25
localeCode - is the parameter that specifies the language that should be set for
the user interface when the user (site owner) logs in to the editor. The following
languages are supported:
en_US - American English
en_GB - British English
de_DE - German
es_ES - Spanish
fr_FR - French
it_IT - Italian
ja_JP - Japanese
nl_NL - Dutch
pl_PL - Polish
pt_BR - Brazilian Portuguese
ru_RU - Russian
zh_CN - simplified Chinese
zh_TW - traditional Chinese
sessionLifeTime - is the parameter that specifies (in seconds) the period of
inactivity for a user’s session in the editor. When this period elapses, the security
token expires and the user needs to log in again.
token - the security token for redirecting a user’s browser to the editor.
wpbUrl - the host name of the server where Presence Builder is installed.
To learn more about these parameters, refer to the section Generating a Security Token for
Accessing a Site (on page 102).
The URL for redirecting the user’s browser to the editor looks like the following:
26 Integrating Parallels Presence Builder Standalone with Your Hosting Software
Deleting Sites from Presence Builder
Your customers will be able to remove their sites from the Presence Builder editor
(unless you prohibit them from doing so (on page 75)), so there is no need to add a
special button for deleting sites to your hosting software. However, you might want to
automate deletion of sites from Presence Builder in cases when the corresponding
user accounts and domains are removed from your hosting platform.
To delete sites, your script must do the following:
1. Connect the API library as described in the section Initializing the API Library (on page
21).
2. Retrieve site IDs for the domain names or user accounts that must be removed.
3. Call the following REST API method through the API library:
$siteUuid; //This is the ID of the site to be deleted
$wpbApi->requestToApi(‘/sites/’ . $siteUuid, WpbApi::DELETE);
This chapter describes how to use the following techniques for upselling hosting
In this chapter:
Upselling Hosting Services with Restricted Functionality Techniques ................28
Upselling Hosting Services with Automated Site Creation ..................................38
Configuring the Promotional Footer ...................................................................40
C H A P T E R 7
Upselling Hosting Services
services:
Differentiation of hosting plans based on the editor’s functionality available to
customers.
Automatic creation of websites for customers who purchase only domain name
registration services.
Showing an advertisement block on websites of the users who are subscribed to
free or low-cost service plans.
28 Upselling Hosting Services
Upselling Hosting Services with Restricted
Functionality Techniques
One of the methods that may help to upsell is differentiation of hosting plans based on the
editor functionality available to customers. For example, you can set up hosting plans that
allow users to create limited numbers of website pages, and you can charge extra money for
the use of the Image Slider, Image Gallery, Map, and other modules.
The following overview describes how the restriction method can be configured and used:
1. You configure how many editor modules or website pages can be used per website. This
can be done by means of the API for both newly created and already existing sites. This
is described in the section Restricting Resources by Means of the API (on page 31).
2. A user logs in to the editor and starts creating a website. When the specified limit for the
number of website pages or site modules is reached, a special icon with a dollar sign
appears.
The icon in the toolbar.
Upselling Hosting Services 29
The icon in the context menu.
30 Upselling Hosting Services
The icon in the page creation wizard.
3. If the user adds one more module or a website page that exceeds the specified limits, he
is prompted to pay for additional resources. Otherwise, he will not be able to publish the
website. The text on the Publish button is changed to Buy and Publish.
Loading...
+ 113 hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.