Forums

Watchman redirect doesn't works

beillard 07 Jul, 2009
Hi,

I try Watchman plugin. I select "register" and activate the plugin, but I can't load the form in the frontend, even if I am logged as "registrer".

In debug mode, I got this message, and in this debug mode the form is loaded.

Thanks for your help.

André

Debug information
Params: JParameter Object ( [_raw] => redirect_url=index.php debug=1 gid=18 redirect_message_users=redirect days=1|2|3|4|5|6|0 open_time=00:00 close_time=00:00 [_xml] => [_elements] => Array ( ) [_elementPath] => Array ( [0] => ..../libraries/joomla/html/parameter/element ) [_defaultNameSpace] => _default [_registry] => Array ( [_default] => Array ( [data] => stdClass Object ( [redirect_url] => index.php [debug] => 1 [gid] => 18 [redirect_message_users] => redirect [days] => Array ( [0] => 1 [1] => 2 [2] => 3 [3] => 4 [4] => 5 [5] => 6 [6] => 0 ) [open_time] => 00:00 [close_time] => 00:00 ) ) ) [_errors] => Array ( ) )

Warning: in_array() [function.in-array]: Wrong datatype for second argument in /.............../components/com_chronocontact/plugins/cf_watchman.php on line 239

Warning: implode() [function.implode]: Invalid arguments passed in /............
/components/com_chronocontact/plugins/cf_watchman.php on line 246 User groups ( [user: 18]) Redirecting Now !!!! to ('redirect_url') with message:
GreyHead 08 Jul, 2009
Hi André,

I'm not sure what is happening here. In my version of the plugin there is some code that is intended to make sure that the datatype is correctly set in line 239.

I'll install fresh copy of the current release and take a look.

Bob
GreyHead 11 Jul, 2009
Hi André,

I found the bug :-(

Apparently $params->set() will only work with a string not an array even though an array is a legitimate parameter.

A modified version of the plugin is attached, please unzip and copy to the components/com_chronocontact/plugins folder.

Bob
beillard 11 Jul, 2009
Hi Bob,

Merci beaucoup

It works perfectly.

Regards

André
knuddi 24 Jul, 2009
I seem to have the similar kind of problem but the attached fix doesn't seem to help me out. I am using Joomla 1.5.11, PHP4, Chronoform 3.1 RC5.3.

My redirect simply shows nothing and the httpd log has these entries.

Any good suggestions?

Regards,
Jesper

httpd: PHP Fatal error: Undefined class name 'self' in /home/e-smith/files/ibays/scanmailx/html/components/com_chronocontact/plugins/cf_watchman.php on line 251

Line 251 is:
$redirected = self::redirect('users', $params, 'User groups ('.implode(', ', $params_gid).' ['.$gid.'])');


Debug information
Params: jparameter Object ( [_raw] => redirect_url=https://www.scanmailx.dk/index.php?option=com_user&view=register debug=1 gid=18 redirect_message_users=This is our message days=1|2|3|4|5|6|0 open_time=00:00 close_time=00:00 [_xml] => [_elements] => Array ( ) [_elementPath] => Array ( [0] => /home/e-smith/files/ibays/scanmailx/html/libraries/joomla/html/parameter/element ) [_errors] => Array ( ) [_defaultNameSpace] => _default [_registry] => Array ( [_default] => Array ( [data] => stdClass Object ( [redirect_url] => https://www.scanmailx.dk/index.php?option=com_user&view=register [debug] => 1 [gid] => 18 [redirect_message_users] => This is our message [days] => Array ( [0] => 1 [1] => 2 [2] => 3 [3] => 4 [4] => 5 [5] => 6 [6] => 0 ) [open_time] => 00:00 [close_time] => 00:00 ) ) ) )
GreyHead 24 Jul, 2009
Hi knuddi,

Yes, 'self' isn't valid in PHP4. Please use the attached copy which doesn't use 'self' I think it was posted somewhere else here a week or two ago.

Bob

Later: attachment updated
knuddi 24 Jul, 2009
You attachment was cf_recaptcha and not cf_watchman - do you have the watchman one as well?

Has PHP4 been discontinued?

/Jesper
GreyHead 24 Jul, 2009
Hi knuddi,

Apologies, it's been that kind of a day. I've changed the attachment on my previous post.

PHP5 was first released in 2004 and the final bug-fix release of PHP4 was in mid-2008 so, yes, it's no longer supported but still in use in some places. If you can I'd update as PHP4 support is ending in many apps (including Joomla 1.6 I think).

Bob
knuddi 25 Jul, 2009
Great - it worked wonders :-) I will get my system up to PHP5 one of these days - seem to be the right time...

Thanks again,
Jesper
This topic is locked and no more replies can be posted.