Seo Suite on Modx 2.8.3

When I install SEO Suite 2.0.2 I get an error on installation and all pages on the frontend disapear and are redirected to a blank 403 error page.

The error is:

/*

  • MODX Console Output
  • @date 2021-06-03 15:32:10
    */
    Attempting to install package with signature: seosuite-2.0.2-pl

Package found…now preparing to install.

Grabbing package workspace…

Workspace environment initiated, now installing package…

Could not create table modx_seosuite_redirect
SQL: CREATE TABLE modx_seosuite_redirect (id INTEGER unsigned NOT NULL AUTO_INCREMENT, context_key VARCHAR(100) NOT NULL DEFAULT ‘’, resource_id INTEGER(10) NOT NULL DEFAULT ‘0’, old_url VARCHAR(255) NOT NULL DEFAULT ‘’, new_url VARCHAR(255) NOT NULL DEFAULT ‘’, redirect_type VARCHAR(75) NOT NULL DEFAULT ‘’, active TINYINT(1) unsigned NOT NULL DEFAULT ‘1’, visits INTEGER(11) NOT NULL DEFAULT ‘0’, last_visit TIMESTAMP NULL DEFAULT ‘0000-00-00 00:00:00’, editedon TIMESTAMP NULL ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id), INDEX context_key (context_key), INDEX resource_id (resource_id), INDEX old_url (old_url), INDEX active (active)) ENGINE=InnoDB
ERROR: Array
(
[0] => 42000
[1] => 1067
[2] => Invalid default value for ‘last_visit’
)

Could not create table modx_seosuite_url
SQL: CREATE TABLE modx_seosuite_url (id INTEGER unsigned NOT NULL AUTO_INCREMENT, context_key VARCHAR(100) NOT NULL DEFAULT ‘’, url VARCHAR(2000) NOT NULL DEFAULT ‘’, suggestions TEXT NULL, visits INTEGER(11) NOT NULL DEFAULT ‘0’, last_visit TIMESTAMP NULL DEFAULT ‘0000-00-00 00:00:00’, createdon TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP, PRIMARY KEY (id), INDEX context_key (context_key), INDEX url (url)) ENGINE=InnoDB
ERROR: Array
(
[0] => 42000
[1] => 1067
[2] => Invalid default value for ‘last_visit’
)

xPDOVehicle resolver failed: type php (/data01/c4106692/modx.forequizzes.co.uk/core/packages/seosuite-2.0.2-pl/modCategory/cb5de4539df5b285650e33f13b6a4df1.setupoptions.resolver.resolver)

Successfully installed package seosuite-2.0.2-pl

/* EOF */

How can I fix this issue?

The problem seems to be that the default value '0000-00-00 00:00:00' is not a valid date.

If you have access to the MySQL config file, you can maybe try to remove NO_ZERO_DATE from sql-mode.

Or you could try to create the tables by hand (for example with phpMyAdmin) by changing '0000-00-00 00:00:00' to a valid date in the SQL command.

I casn’t get SQL to to acceot a date or time. is there a format I need to be using?

Maybe use something like this '1970-01-01 01:01:01'.
Perhaps you can also omit the default value as the column allows NULL values.

Thanks, now getting this issue:

Static analysis:

4 errors were found during analysis.

  1. An alias was previously found. (near “:01’” at position 446)
  2. A comma or a closing bracket was expected. (near “:01’” at position 446)
  3. Unexpected beginning of statement. (near “id” at position 518)
  4. Unrecognized statement type. (near “INDEX” at position 523)

SQL query:

CREATE TABLE modx_seosuite_redirect (id INTEGER unsigned NOT NULL AUTO_INCREMENT, context_key VARCHAR(100) NOT NULL DEFAULT ‘’, resource_id INTEGER(10) NOT NULL DEFAULT ‘0’, old_url VARCHAR(255) NOT NULL DEFAULT ‘’, new_url VARCHAR(255) NOT NULL DEFAULT ‘’, redirect_type VARCHAR(75) NOT NULL DEFAULT ‘’, active TINYINT(1) unsigned NOT NULL DEFAULT ‘1’, visits INTEGER(11) NOT NULL DEFAULT ‘0’, last_visit TIMESTAMP NULL DEFAULT ‘1970-01-01 01:01:01’, editedon TIMESTAMP NULL ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (id), INDEX context_key (context_key), INDEX resource_id (resource_id), INDEX old_url (old_url), INDEX active (active)) ENGINE=InnoDB

MySQL said:

#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '‘’, resource_id INTEGER(10) NOT NULL DEFAULT ‘0’, old_url VARCHAR(255) N' at line 1

Make sure all the apostrophes/single quotes in your SQL command are ' and not or .

It is now working and am now getting the error:
xPDOVehicle resolver failed: type php (/data01/c4106692/modx.forequizzes.co.uk/core/packages/seosuite-2.0.2-pl/modCategory/cb5de4539df5b285650e33f13b6a4df1.setupoptions.resolver.resolver)

Also front pages are getting 403 error