Page 2 of 2 FirstFirst 12
Results 11 to 20 of 20
  1. #11
    Join Date
    Jan 2009
    Posts
    50
    Plugin Contributions
    0

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    Hello

    thank you for the quick reply

    I fixed th problem by doing so:

    To eliminate thee array_merge() errors, edit the admin/customers.php file:

    Find these lines:

    Code:
    $customer_info = array_merge($country, $info, $reviews);
    
    $cInfo_array = array_merge($customers, $customer_info);


    and change them to:

    Code:
    $customer_info = array_merge((array)$country, (array)$info, (array)$reviews);
    
    $cInfo_array = array_merge((array)$customers, (array)$customer_info);
    ...........Being zenned............

  2. #12
    Join Date
    Apr 2006
    Location
    London, UK
    Posts
    10,569
    Plugin Contributions
    25

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    That will certainly deal with the immediate error, where the error shows that its on the customer page (similar errors have been reported elsewhere), but be on your guard for further problems as it may just mask an underlying problem (why the array hadn't been set in the first place) which could then manifest itself elsewhere.

    Thanks for posting back the location though, that may be helpful if others suffer this problem.
    Kuroi Web Design and Development | Twitter

    (Questions answered in the forum only - so that any forum member can benefit - not by personal message)

  3. #13
    Join Date
    Jan 2004
    Posts
    66,419
    Blog Entries
    7
    Plugin Contributions
    277

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    What you've done there is merely mask a problem you've got in the integrity of the data in your database.
    You've clearly got broken relationships between your customers, customers_info, and address_book tables. This is ALWAYS caused by importing data incorrectly and/or manually fiddling with data in the database.

    You should really fix your database integrity problems instead of merely masking them.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  4. #14
    Join Date
    Jan 2009
    Posts
    50
    Plugin Contributions
    0

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    Hello

    thank you Dr byte :| I dunno vry well the structure of Zencart

    I added a field to the customer table, you think this is what caused it?
    ...........Being zenned............

  5. #15
    Join Date
    Jan 2004
    Posts
    66,419
    Blog Entries
    7
    Plugin Contributions
    277

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    possibly
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  6. #16
    Join Date
    Jan 2009
    Posts
    50
    Plugin Contributions
    0

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    could you plz advice me further what to check?
    ...........Being zenned............

  7. #17
    Join Date
    Dec 2007
    Posts
    8
    Plugin Contributions
    0

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    Quote Originally Posted by joudesign View Post
    Hello

    thank you for the quick reply

    I fixed th problem by doing so:

    To eliminate thee array_merge() errors, edit the admin/customers.php file:

    Find these lines:

    Code:
    $customer_info = array_merge($country, $info, $reviews);
    
    $cInfo_array = array_merge($customers, $customer_info);

    and change them to:

    Code:
    $customer_info = array_merge((array)$country, (array)$info, (array)$reviews);
    
    $cInfo_array = array_merge((array)$customers, (array)$customer_info);
    thank you,
    It's work with my site.

  8. #18
    Join Date
    Nov 2007
    Posts
    433
    Plugin Contributions
    1

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    OK I had the same problem and I just downloaded a new version of zencart, registered some test customers and I am getting those lines of errors :
    Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home1/arabbro1/public_html/pc2all/admin/customers.php on line 1099

    Warning: array_merge() [function.array-merge]: Argument #2 is not an array in /home1/arabbro1/public_html/pc2all/admin/customers.php on line 1101

    Warning: reset() [function.reset]: Passed variable is not an array or object in /home1/arabbro1/public_html/pc2all/admin/includes/classes/object_info.php on line 29

    Warning: Variable passed to each() is not an array or object in /home1/arabbro1/public_html/pc2all/admin/includes/classes/object_info.php on line 30

    I can't even delete any customer!! please check my customers file
    Attached Files Attached Files

  9. #19
    Join Date
    Jan 2004
    Posts
    66,419
    Blog Entries
    7
    Plugin Contributions
    277

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    Either your countries table is empty, or the customer you added is connected to a country which you've deleted from the database.
    You can't go deleting data and not encounter errors.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  10. #20
    Join Date
    Nov 2007
    Posts
    433
    Plugin Contributions
    1

    Default Re: Warning: array_merge() [function.array-merge]: Argument #1 is not an array in

    Thanks DrByte, I fixed it, You maybe right about that because I indeed deleted all the countries from my phpmyadmin side and left only one, for customers also I had to delete them from the phpmyadmin side and when I created a test customer to edit/delete his info, I could do that luckily .. Thanks again ..

 

 
Page 2 of 2 FirstFirst 12

Similar Threads

  1. Warning: array_merge() [function.array-merge]: Argument #1 is not an array
    By antieuclid in forum PayPal Express Checkout support
    Replies: 3
    Last Post: 19 Jul 2010, 02:50 AM
  2. Replies: 2
    Last Post: 29 Nov 2009, 06:01 AM
  3. Replies: 1
    Last Post: 14 Mar 2008, 02:58 AM
  4. Error: Argument #1 is not an array in
    By Fuzion in forum Managing Customers and Orders
    Replies: 2
    Last Post: 2 Feb 2008, 07:57 AM
  5. function.array-merge error
    By conexion in forum PayPal Express Checkout support
    Replies: 2
    Last Post: 8 Apr 2007, 02:35 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR