MyBB Community Forums

Full Version: php error
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
this in my years of PHP work I never ran across this error anyone know how to fix


Quote:Warning: Wrong parameter count for str_replace()

the line of code that its showing is

$this->ipsclass->member['members_display_name'] = str_replace( "<br />", "<br>", "\r\n", "&nbsp;", $this->ipsclass->member['members_display_name'] );


WARNING THIS IS NOT A IPS OWNED MODULE so I am not asking for help with another website's module this is my module for integrating IRC with IPB, mybb and others
$this->ipsclass->member['members_display_name'] = str_replace(array("<br />", "<br>", "\r\n"), "&nbsp;", $this->ipsclass->member['members_display_name'] );
Tikitiki Wrote:$this->ipsclass->member['members_display_name'] = str_replace(array("<br />", "<br>", "\r\n"), "&nbsp;", $this->ipsclass->member['members_display_name'] );

that work

and your name is now commented in my code

/**
		* Dis-Allow a wrong style spaces & linebreaks in usernames
		*
		* Bug# 87 Fix thanks to Tikitiki of MyBB
		*/
		$this->ipsclass->member['members_display_name'] = str_replace(array("<br />", "<br>", "\r\n"), "&nbsp;", $this->ipsclass->member['members_display_name'] );
No problemo