After running the upgrade process from 2.01 to 2.02 I noticed that some fields within Admin Settings wasn’t populated with any data on some of the YES/NO fields.
I then noticed the following error on existing referred submitted sites
———————–ERROR START——————
/admin/site/edit/17
http://directory.linkexchangeforum.co.uk/admin/referrer
(8) Undefined index: siteDescriptionHtmlEnabledAdmin c_1_site_edit_tpl.php line 241 26-11-10 10:42
FrontController->dispatch() # line 18, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/index.php
Controller->render() # line 225, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/core/FrontController.php
TemplateLiteView->render(Object:Admin_SiteController) # line 167, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/core/Controller.php
Template_Lite->fetch(“site/edit.tpl”) # line 77, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/views/TemplateLiteView.php
Template_Lite->_fetch_compile(“site/edit.tpl”, null) # line 360, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/components/template_lite/class.template.php
include(“/home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/co…”) # line 482, file: /home/sites/linkexchangeforum.co.uk/public_html/linkdirectory/components/template_lite/class.template.php
———————–ERROR END——————
The error is down to the database update query – “update202.php” which seems to have been unsuccessfully. I think the reason it errors is something to do with the task update. As tasks only show after being run in the db.
———————-mysql update script issue start—————————-
$sqls[] = “ALTER TABLE `”.$dbConfig[‘DB_PREFIX’].”tasks`
CHANGE `data` `data` longtext NOT NULL”;
———————-mysql update script issue end—————————-
After checking the “settings” table in phpmyadmin I spotted some fields wasn’t inserted into the table called settings.
I had to adapt the “update202.php” to only carry out the below update which resolved my issue my removing all other sql update scripts that had successfully updated already.
$sqls[] = “INSERT INTO “.$dbConfig[‘DB_PREFIX’].”settings (`key` , `value` )
VALUES
(‘siteDescriptionHtmlEnabled’, ‘0’),
(‘siteDescriptionHtmlAllowedTags’, ‘a[href|title|target], br, b, p, ul, ol, li, table[cellspacing|cellpadding|border], tbody, tr, td[colspan|rowspan], strong, span, em, *[style], *[class], img[src]’),
(‘siteDescriptionHtmlAllowedCssProperties’, ‘text-align, color, background-color, font-family, font-size, border, text-decoration, padding-left, height, width, font-weight’),
(‘campaignFilters’, ”),
(‘siteDescriptionHtmlEnabledAdmin’, ‘0’),
(‘siteDescriptionHtmlAllowedTagsAdmin’, ‘a[href|title|target], br, b, p, ul, ol, li, table[cellspacing|cellpadding|border], tbody, tr, td[colspan|rowspan], strong, span, em, *[style], *[class], img[src]’),
(‘siteDescriptionHtmlAllowedCssPropertiesAdmin’, ‘text-align, color, background-color, font-family, font-size, border, text-decoration, padding-left, height, width, font-weight’),
(‘duplicateContentCheckerEnabled’, ‘0’),
(‘duplicateContentCheckerPhrasesToCheckCount’, ‘3’),
(‘duplicateContentCheckerWordsInPhraseCount’, ‘6’),
(‘duplicateContentCheckerAllowableDuplicatedPhrasesCount’, ‘0’)”;
Hope this helps any others who may have come across this issue after upgrading.
Craig