Title: PHP array problem in WP plugin
Last modified: August 31, 2016

---

# PHP array problem in WP plugin

 *  [kelecz](https://wordpress.org/support/users/kelecz/)
 * (@kelecz)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/)
 * Guys,
    need help.
 * Those are errors:
 * [https://mega.nz/#!iBA2hYDB!WayC-AWYO4PafNZ9f6kyoeaUicaYn-mWtJtMVillfDo](https://mega.nz/#!iBA2hYDB!WayC-AWYO4PafNZ9f6kyoeaUicaYn-mWtJtMVillfDo)
 * and this is code :
 *     ```
       $dropdown_cities = array_reduce( $cities, 'array_merge', array() );
       					sort( $dropdown_cities ) ;
       				}
   
       				foreach ( $dropdown_cities as $city_name ) {
       ```
   
 * What should I correct here?
 * THX!

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

 *  [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373518)
 * Hi,
 * Unfortunately I can’t view the errors as that site is blocked where I am (and,
   indeed, you might find some people won’t follow links such as that as it may 
   lead anywhere!).
 * However, you say in your title that this is from a plugin? Have you tried the
   support forum for that plugin for assistance?
 * David.
 *  Thread Starter [kelecz](https://wordpress.org/support/users/kelecz/)
 * (@kelecz)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373535)
 * Yes I have. No help, they said that will try…
 * New link:
 * [http://s32.postimg.org/gbdnmpjr9/screenshot_localhost_2016_05_12_13_24_44.png](http://s32.postimg.org/gbdnmpjr9/screenshot_localhost_2016_05_12_13_24_44.png)
 * Thx
 *  [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373546)
 * No, that link isn’t accessible either. Can you just cut/paste them here?
 * David.
 *  Thread Starter [kelecz](https://wordpress.org/support/users/kelecz/)
 * (@kelecz)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373549)
 * Here we go:
 * Warning: array_merge(): Argument #2 is not an array in D:\local\htdocs\mr\wp-
   content\plugins\wc-…-master\wc-…-select.php on line 135
 * Warning: array_merge(): Argument #1 is not an array in D:\local\htdocs\mr\wp-
   content\plugins\wc-…-master\wc-…-select.php on line 135
 * Warning: sort() expects parameter 1 to be array, null given in D:\local\htdocs\
   mr\wp-content\plugins\wc-…-master\wc-…-select.php on line 136
 * Regards
 *  [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373551)
 * Thanks, although I’ll need to know the missing bits – all those dots are hiding
   filenames that I need to know (I don’t know which plugin we’re talking about,
   for instance).
 * David.
 *  Thread Starter [kelecz](https://wordpress.org/support/users/kelecz/)
 * (@kelecz)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373557)
 * Here they are:
 * wc-city-select-master\wc-city-select.php
 *  [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373560)
 * Have you changed your user ID? Only, I can’t see any request for help at the 
   plugin forum. Here is the one…
 * [https://wordpress.org/support/plugin/wc-city-select](https://wordpress.org/support/plugin/wc-city-select)
 * They appear to be pretty quick at their responses and, as it’s their code, I’m
   sure they’ll be be able to work out the cause far quicker than I could!
 * David.
 *  Thread Starter [kelecz](https://wordpress.org/support/users/kelecz/)
 * (@kelecz)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373595)
 * Thank you,
 * I wrote to him on Github. No response yet. But I am optimist.:)
    THX again!
 *  [David Artiss](https://wordpress.org/support/users/dartiss/)
 * (@dartiss)
 * [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373616)
 * Hi,
 * I’ve found your conversation on GitHub and it looks as if the developer has pushed
   out a change to fix your issue…
 * [https://github.com/8manos/wc-city-select/issues/7](https://github.com/8manos/wc-city-select/issues/7)
 * Can you confirm this is resolved?
 * David.

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

The topic ‘PHP array problem in WP plugin’ is closed to new replies.

## Tags

 * [array](https://wordpress.org/support/topic-tag/array/)
 * [city](https://wordpress.org/support/topic-tag/city/)
 * [code](https://wordpress.org/support/topic-tag/code/)
 * [php](https://wordpress.org/support/topic-tag/php/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 9 replies
 * 2 participants
 * Last reply from: [David Artiss](https://wordpress.org/support/users/dartiss/)
 * Last activity: [10 years, 1 month ago](https://wordpress.org/support/topic/php-array-problem-in-wp-plugin/#post-7373616)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
