Fatal error: Cannot redeclare tc_post()

The entire error I recieved was: Fatal error: Cannot redeclare tc_post() (previously declared in www/wp-content/plugins/text-control.php:20) in www/wp-content/plugins/text-control/text-control.php on line 33

When upgrading the WordPress plugin text-control I was getting this error when trying to activate text-control. I ended up remembering that the markdown.php had not worked on initial installation so I replaced it with the markdown.php from the WordPress plugin PHP Markdown Extra which resolved my initial issue.

The text-control plugin did not have an update but it thought it did because the version number of the markdown.php file was incorrect. Anyhow the above error appears to have been caused by the fact that during the attempted auto upgrade it created a sub directory under text-control by the name of text-control which technically had the files needed by text-control.php in the wrong place. To resolve the issue I moved the four files named textile1.php, textile2.php, smartypants.php, and markdown.php up one directory and removed any other files (including text-control.php) besides the four previously listed from wp-content/plugins/text-control/.

Share