Title: PHP Deprecated function Notice: Array to string conversion
Last modified: November 17, 2020

---

# PHP Deprecated function Notice: Array to string conversion

 *  [w4cdev](https://wordpress.org/support/users/w4cdev/)
 * (@w4cdev)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/php-deprecated-function-notice-array-to-string-conversion/)
 * Notice: Array to string conversion in watchman-site7/class-wms7-core.php on line
   407
 * `
    // get user cookie. $user_cookie = ”; foreach ( $_arr_cookie as $key => $value){
   $user_cookie = $user_cookie . $key . ‘=’ . $value . ‘ ’; }
 * The errors are notified due to value defined in alpha, numeric and special characters
   which is combination that afraid’s us to get the results.
 * What is the best enumeration to build this result and get rid of the above php
   deprecation

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

 *  Thread Starter [w4cdev](https://wordpress.org/support/users/w4cdev/)
 * (@w4cdev)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/php-deprecated-function-notice-array-to-string-conversion/#post-13671578)
 * Hope it will also effects the fllowing bunch of code to execute having same issue
 *     ```
       // get user IP.
       $this->user_ip = ( $_forward_for ) ? $_forward_for : $_remote_addr;
   
       // get user info.
       $info_add     = $this->wms7_get_user_ip();
       $user_ip_info = '---Visit page information-------------
       ' .
       'REQUEST_URI = ' . $_request_uri . '
       ' .
       'SERVER_ADDR = ' . $_server_addr . '
       ' .
       'SERVER_NAME = ' . $_server_name . '
       ' .
       'SERVER_SOFTWARE = ' . $_server_software . '
       ' . $info_add . '
       ' . '---Information about the Cookie visitor---
       ' .
       $user_cookie;
       ```
   
 *  Plugin Author [adminkov](https://wordpress.org/support/users/adminkov/)
 * (@adminkov)
 * [5 years, 6 months ago](https://wordpress.org/support/topic/php-deprecated-function-notice-array-to-string-conversion/#post-13671728)
 * Hello dear w4cdev. Thank you for your comments on the WatchMan-Site7 plugin
    
   I end up collecting all the errors and bad code snippets of this plugin. And 
   from December 2020 I will start a major rework of the entire plugin. In general,
   the interface and functionality will remain the same, but I want to thoroughly
   clean up the code and make it clear, rational, without unnecessary code fragments.
   I will be grateful if you will inform me about the found errors in the code of
   this plugin. Best regards, adminkov.
 *  Plugin Author [adminkov](https://wordpress.org/support/users/adminkov/)
 * (@adminkov)
 * [5 years, 4 months ago](https://wordpress.org/support/topic/php-deprecated-function-notice-array-to-string-conversion/#post-13940632)
 * A new version of the WatchMan-Site7 plugin v.4.0.0 has been released
    Try it 
   in action. If there are any mistakes, let me know. Thank you.

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

The topic ‘PHP Deprecated function Notice: Array to string conversion’ is closed
to new replies.

 * ![](https://ps.w.org/watchman-site7/assets/icon-128x128.png?rev=1792176)
 * [WatchMan-Site7](https://wordpress.org/plugins/watchman-site7/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/watchman-site7/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/watchman-site7/)
 * [Active Topics](https://wordpress.org/support/plugin/watchman-site7/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/watchman-site7/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/watchman-site7/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [adminkov](https://wordpress.org/support/users/adminkov/)
 * Last activity: [5 years, 4 months ago](https://wordpress.org/support/topic/php-deprecated-function-notice-array-to-string-conversion/#post-13940632)
 * Status: not resolved