Parse error: Unexpected T_FUNCTION

Do you see the following error?

Parse error: syntax error, unexpected T_FUNCTION in/PATH_TO_WORDPRESS/wp-content/plugins/PATH_TO/file.php on line 41

Typically, we see these types of errors when your server is running an older version of PHP and certain versions of our plugins.

Update PHP to current version

You can check the version of PHP your webhost has installed on your server by adding a PHPinfo file or by contacting your webhost support team for assistance. If you confirm the server is running a version earlier than PHP 5.3, upgrade to a current PHP version to immediately resolve the issue.

Update Yoast SEO plugin to current version

Please manually update your Yoast SEO plugin to the current version to see if the issue is resolved. An update guide is available for the free plugins and the premium plugins. If you are running the newest version of Yoast SEO, please report the issue in the appropriate channel.

Did this article answer your question?

Thanks for your feedback!

Related articles

Get free SEO tips!