Sitebuilder database has non-UTF8 character set

Created:

2017-03-18 11:14:56 UTC

Modified:

2017-08-08 13:45:50 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Sitebuilder database has non-UTF8 character set

Symptoms

The following error is shown when try to open site in Sitebuilder wizard:

Internal Sitebuilder error.

     File: /usr/local/sitebuilder/include/Base/GUI.php
     Line: 101
     Message: PHP Warning : DOMDocument::loadXML() [<a href='function.DOMDocument-loadXML'>function.DOMDocument-loadXML</a>]: internal errorExtra content at the end of the document in Entity, line: 659
     Code: 2

Cause

In Plesk Sitebuilder version 4.5 site's content is stored in Sitebuilder database. Every time you open site in Wizard the content is compiled anew. The problem is caused not-printable or non-UTF8 symbols existing in the database, and the page cannot be compiled with the error.

By default Sitebuilder database has character set utf8.

mysql> show create database sitebuilder3;
 +--------------+-----------------------------------------------------------------------+
 | Database     | Create Database                                                              |
 +--------------+-----------------------------------------------------------------------+
 | sitebuilder3 | CREATE DATABASE `sitebuilder3` /*!40100 DEFAULT CHARACTER SET utf8 */ |
 +--------------+-----------------------------------------------------------------------+
 1 row in set (0.00 sec)

 mysql>

If another default character set is specified this may cause appearance of invalid characters in the database.

Resolution

To prevent appearance of non-UTF8 symbols on site's pages you need to change default character set for Sitebuilder database to utf8.

Do that with the following command:

mysql> alter database sitebuilder3 default character set utf8;
 Query OK, 1 row affected (0.00 sec)

 mysql>

This will not resolve the problem for existent non-UTF8 symbols but prevents their appearance in future.

Note: During installation Sitebuilder sets default character set UTF8 for the database. The default character set might be changed some other way.

Have more questions? Submit a request
Please sign in to leave a comment.