Page 1 of 1

SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 26 Mar 2008, 21:12
by dialexia
Mantis version = 1.1.1

Can someone help me with this error i get each time I try to report an issue:

SYSTEM WARNING
implode() [function.implode]: Bad arguments.

Please use the "Back" button in your web browser to return to the previous page. There you can correct whatever problems were identified in this error or select another action. You can also click an option from the menu bar to go directly to a new section.

Re: SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 27 Mar 2008, 05:06
by vboctor
Place the following code in your config_inc.php to gather more information about the stack trace of the error:

Code: Select all

	$g_show_detailed_errors	= ON;

	$g_display_errors = array(
		E_WARNING => 'halt',
		E_NOTICE => 'halt',
		E_USER_ERROR => 'halt',
		E_USER_WARNING => 'halt',
		E_USER_NOTICE => 'halt'
	);

Re: SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 27 Mar 2008, 13:06
by dialexia
Here are the results of the error:

Full path: C:\Inetpub\mantis-1.1.1\core\gpc_api.php
Line: 120
Variable Value Type
p_var_name custom_field_2 string
p_custom_field_type 7 string
p_default Coding string
t_values Coding string

Filename Line Function Args
C:\Inetpub\mantis-1.1.1\core\gpc_api.php 120 implode ( '|', 'Coding' )
C:\Inetpub\mantis-1.1.1\bug_report.php

Re: SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 27 Mar 2008, 15:46
by vboctor
Please report a bug in the bug tracker with the information you have gathered.

Re: SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 27 Mar 2008, 19:14
by dialexia
Thank you....I will do that right away.

Many thanx for helping me out here :wink:

Re: SYSTEM WARNING implode() [function.implode]: Bad arguments.

Posted: 31 Oct 2008, 15:30
by dialexia
Hey all,

There a temporary workaround for this issue, provided by bugtracker user giesen. The fix is as follows:

Just change line 119 in core\gpc_api.php from
if( null !== $t_values && '' != $t_values) {
to
if( null !== $t_values && '' != $t_values && is_array($t_values)) {
It works for both mantis-1.1.1 and mantis-1.1.2.

Many thanx to giesen for the fix! Here's the hyperlink for the full history:

http://www.mantisbt.org/bugs/view.php?id=9017