Title: PHP Error when activating with WPML
Last modified: April 19, 2018

---

# PHP Error when activating with WPML

 *  Resolved [Corey Allen](https://wordpress.org/support/users/coreya/)
 * (@coreya)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-error-when-activating-with-wpml/)
 * After activating GDPR Framework I get the following error message:
 *     ```
       ( ! ) Warning: Invalid argument supplied for foreach() in /app/public/wp-content/plugins/gdpr-framework/src/Modules/WPML/WPML.php on line 81
       Call Stack
       #	Time	Memory	Function	Location
       1	0.0000	366472	{main}( )	.../plugins.php:0
       2	0.0004	367144	require_once( '/app/public/wp-admin/admin.php' )	.../plugins.php:10
       3	0.0004	367624	require_once( '/app/public/wp-load.php' )	.../admin.php:31
       4	0.0005	368360	require_once( '/app/public/wp-config.php' )	.../wp-load.php:37
       5	0.0005	375424	require_once( '/app/public/wp-settings.php' )	.../wp-config.php:96
       6	0.6277	15518680	do_action( )	.../wp-settings.php:450
       7	0.6277	15519056	WP_Hook->do_action( )	.../plugin.php:453
       8	0.6277	15519056	WP_Hook->apply_filters( )	.../class-wp-hook.php:310
       9	0.6372	15556208	Codelight\GDPR\Components\Consent\ConsentManager->registerCustomConsentTypes( )	.../class-wp-hook.php:286
       10	0.6372	15556208	Codelight\GDPR\Options\Options->get( )	.../ConsentManager.php:125
       11	0.6376	15544744	apply_filters( )	.../Options.php:28
       12	0.6376	15545144	WP_Hook->apply_filters( )	.../plugin.php:203
       13	0.6376	15546648	Codelight\GDPR\Modules\WPML\WPML->getConsentTypes( )	.../class-wp-hook.php:286
   
       ( ! ) Warning: Cannot modify header information - headers already sent by (output started at /app/public/wp-content/plugins/gdpr-framework/src/Modules/WPML/WPML.php:81) in /app/public/wp-admin/includes/misc.php on line 1116
       Call Stack
       #	Time	Memory	Function	Location
       1	0.0000	366472	{main}( )	.../plugins.php:0
       2	0.0004	367144	require_once( '/app/public/wp-admin/admin.php' )	.../plugins.php:10
       3	1.1184	18888920	do_action( )	.../admin.php:156
       4	1.1184	18889296	WP_Hook->do_action( )	.../plugin.php:453
       5	1.1184	18889296	WP_Hook->apply_filters( )	.../class-wp-hook.php:310
       6	1.2349	19185248	wp_admin_headers( )	.../class-wp-hook.php:286
       7	1.2349	19185568	header ( )	.../misc.php:1116
       ```
   

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [indrek_k](https://wordpress.org/support/users/indrek_k/)
 * (@indrek_k)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-error-when-activating-with-wpml/#post-10199761)
 * Hi there!
 * Thanks for the bug report! Looking into this, hopefully will be fixed with an
   update tomorrow.
 *  [indrek_k](https://wordpress.org/support/users/indrek_k/)
 * (@indrek_k)
 * [8 years, 1 month ago](https://wordpress.org/support/topic/php-error-when-activating-with-wpml/#post-10203307)
 * This should be fixed with v1.0.4 – please update and let me know if there are
   still issues!

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP Error when activating with WPML’ is closed to new replies.

 * ![](https://ps.w.org/gdpr-framework/assets/icon.svg?rev=2304387)
 * [The GDPR Framework By Data443](https://wordpress.org/plugins/gdpr-framework/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/gdpr-framework/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/gdpr-framework/)
 * [Active Topics](https://wordpress.org/support/plugin/gdpr-framework/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/gdpr-framework/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/gdpr-framework/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [indrek_k](https://wordpress.org/support/users/indrek_k/)
 * Last activity: [8 years, 1 month ago](https://wordpress.org/support/topic/php-error-when-activating-with-wpml/#post-10203307)
 * Status: resolved