I have a ModX 1.0.1 installation that has been running for a long time with no flaws or issues. Today when I checked the site everything had gone wrong. I received this parser error.
« MODx Parse Error »
MODx encountered the following error while attempting to parse the requested resource:
« PHP Parse Error »
PHP error debug
Error: mysql_connect() [function.mysql-connect]: Premature end of data (mysqlnd_wireprotocol.c:554)
Error type/ Nr.: Warning - 2
File: /usr/www/users/ebhfh/manager/includes/extenders/dbapi.mysql.class.inc.php
Line: 89
Line 89 source: if (!$this->conn = ($persist ? mysql_pconnect($host, $uid, $pwd) : mysql_connect($host, $uid, $pwd, true))) {
Parser timing
MySQL: 0.0000 s (0 Requests)
PHP: 0.0513 s
Total: 0.0513 s
The page continued to try and connect and the parser timing error continued to fill down the page each time it tried to connect to the db.
I checked the db and the password/user are still the same.
On this post:
http://modxcms.com/forums/index.php/topic,2091.0.html
xwisdom suggests running this script in my PHPadmin. Would this fix anything here? I don’t want to run the script before I really know what it does since I’m not 100% familiar with mySQL.
SELECT DISTINCT sc.published FROM `modx`.dry_site_content sc LEFT JOIN `modx`.dry_document_groups dg on dg.document = sc.id WHERE (sc.id IN (19) AND sc.published=1 AND sc.deleted=0 ) AND (sc.privateweb=0) LIMIT 1
Thanks in advance for your help.