This thread is resolved. Here is a description of the problem and solution.
Problem: After activating the WPML plugin, the client received multiple warnings stating 'Cannot modify header information - headers already sent by' in various PHP files. Solution: We recommend temporarily deactivating all plugins except WPML to check if the warnings still appear. It is crucial to back up your database before making any changes. If the problem persists, it might be due to a specific plugin conflict or a server configuration issue.
Please note that this solution might be outdated or not applicable to your specific case. We highly recommend checking related known issues at https://wpml.org/known-issues/, verifying the version of the permanent fix, and confirming that you have installed the latest versions of themes and plugins. If the issue continues, please open a new support ticket at WPML support forum for further assistance.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
Background of the issue:
I activated the WPML plugin, but it created some bugs. Here is the message: Warning: Cannot modify header information - headers already sent by (output started at /home/fredjourdain/impression.fredjourdain.com/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/wpml/src/UserInterface/Web/Infrastructure/WordPress/CompositionRoot/Config/ExistingPage/PostEditPage.php:23) in /home/fredjourdain/impression.fredjourdain.com/wp-includes/functions.php on line 7168. Warning: Cannot modify header information - headers already sent by (output started at /home/fredjourdain/impression.fredjourdain.com/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/wpml/src/UserInterface/Web/Infrastructure/WordPress/CompositionRoot/Config/ExistingPage/PostEditPage.php:23) in /home/fredjourdain/impression.fredjourdain.com/wp-includes/functions.php on line 7144. Warning: Cannot modify header information - headers already sent by (output started at /home/fredjourdain/impression.fredjourdain.com/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/wpml/src/UserInterface/Web/Infrastructure/WordPress/CompositionRoot/Config/ExistingPage/PostEditPage.php:23) in /home/fredjourdain/impression.fredjourdain.com/wp-admin/post.php on line 231. Warning: Cannot modify header information - headers already sent by (output started at /home/fredjourdain/impression.fredjourdain.com/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/wpml/src/UserInterface/Web/Infrastructure/WordPress/CompositionRoot/Config/ExistingPage/PostEditPage.php:23) in /home/fredjourdain/impression.fredjourdain.com/wp-includes/pluggable.php on line 1450. Warning: Cannot modify header information - headers already sent by (output started at /home/fredjourdain/impression.fredjourdain.com/wp-content/plugins/sitepress-multilingual-cms/vendor/wpml/wpml/src/UserInterface/Web/Infrastructure/WordPress/CompositionRoot/Config/ExistingPage/PostEditPage.php:23) in /home/fredjourdain/impression.fredjourdain.com/wp-includes/pluggable.php on line 1453.
Symptoms:
I am receiving multiple warnings about 'Cannot modify header information - headers already sent by' in various PHP files.