Warning: implode() [function.implode]: Invalid arguments ???

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
Imi78
Forum Newbie
Posts: 3
Joined: Wed Apr 08, 2009 3:48 pm

Warning: implode() [function.implode]: Invalid arguments ???

Post by Imi78 »

Hello,

i am a totally noob with PHP.

Following problem:

I am moving my oscommerce-shop from my local XAMPP-Server to the hosted server. After copying the files and adapting the shop

i get this error message:


Warning: implode() [function.implode]: Invalid arguments passed in /catalog/includes/functions/header_tags.php on line 60

Warning: implode() [function.implode]: Invalid arguments passed in /catalog/includes/functions/header_tags.php on line 61

Warning: implode() [function.implode]: Invalid arguments passed in /catalog/includes/functions/header_tags.php on line 62

This is the mentioned code:

$header_tags_array['desc'] = ltrim(tep_db_prepare_input(implode(' ' . HEADER_TAGS_SEPARATOR_DESCRIPTION . ' ', $sortOrder['description'])), ' ' . HEADER_TAGS_SEPARATOR_DESCRIPTION);
$header_tags_array['keywords'] = ltrim(tep_db_prepare_input(implode(' ' . HEADER_TAGS_SEPARATOR_KEYWORD . ' ', $sortOrder['keywords'])), ' ' . HEADER_TAGS_SEPARATOR_KEYWORD);
$header_tags_array['logo_text'] = ltrim(tep_db_prepare_input(implode(' ' . HEADER_TAGS_SEPARATOR_DESCRIPTION . ' ', $sortOrder['logo'])), ' ' . HEADER_TAGS_SEPARATOR_DESCRIPTION);

Whats wrong?? Wrong PHP-Settings on the server?

Greets

ImI
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: Warning: implode() [function.implode]: Invalid arguments ???

Post by Christopher »

My guess is that $sortOrder['description'], $sortOrder['keywords'] and $sortOrder['logo'] are not arrays.
(#10850)
Imi78
Forum Newbie
Posts: 3
Joined: Wed Apr 08, 2009 3:48 pm

Re: Warning: implode() [function.implode]: Invalid arguments ???

Post by Imi78 »

mhhhh.....but isnt it strange that everything works on XAMPP?? Could the PHP-Settings be wrong??
User avatar
Christopher
Site Administrator
Posts: 13596
Joined: Wed Aug 25, 2004 7:54 pm
Location: New York, NY, US

Re: Warning: implode() [function.implode]: Invalid arguments ???

Post by Christopher »

Not wrong, but perhaps the error settings are different. Those are Warnings, not Errors. But they mean it is not really "working" even if one is set to not show Warnings.
(#10850)
Imi78
Forum Newbie
Posts: 3
Joined: Wed Apr 08, 2009 3:48 pm

Re: Warning: implode() [function.implode]: Invalid arguments ???

Post by Imi78 »

I solved it. It was a oscommerce-contribution that wasnt configured as it should have been.

THX!

ImI
Post Reply