TN3 Gallery for WordPress – Important installation note

Maybe you get blank images after ajax uploads using the TN3 gallery WordPress plugin.

A table of the TN3 WordPress plugin database schema has a FULLTEXT index and it has not been created if you use InnoDB as default engine. Therefore, to solve the problem:

  • use MyISAM as default engine for new tables OR
  • add “) DEFAULT CHARSET=utf8, ENGINE = MyISAM;” at line 108 of wp-content/plugins/tn3-gallery/tn3-gallery.php + trash previously created tables if necessary + disable and re-enable the plugin OR
  • execute this script on the database to add only the missing table (if you use InnoDB as default engine) :


CREATE TABLE IF NOT EXISTS `wp_tn3_fields` (
`docid` bigint(20) NOT NULL,
`name` varchar(20) NOT NULL,
`value_type` varchar(10) NOT NULL,
`value_text` text,
`value_date` datetime DEFAULT NULL,
`value_number` decimal(20,8) DEFAULT NULL,
`value_bool` char(1) DEFAULT NULL,
`value_comp` text,
PRIMARY KEY (`docid`,`name`),
KEY `ind_val_text` (`value_text`(100)),
KEY `ind_val_date` (`value_date`),
KEY `ind_val_number` (`value_number`),
KEY `ind_val_bool` (`value_bool`),
FULLTEXT KEY `ind_ft` (`value_text`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.