Forum plugin and CAPTCHA image issues
Forum plugin and CAPTCHA image issues
Hello everyone,
Sorry to bug you all with these issues but I am losing my mind trying to resolve them. I have searched the forums and tried many fixes, but still have the same issues. Here is what I am struggling with:
1) I have installed the Forum plugin and when I try to add a comment or view a comment, I get the following error: Warning: explode() expects parameter 2 to be string, array given in C:\Inetpub\barodsandperformancenew\serendipity\plugins\serendipity_event_spamblock\serendipity_event_spamblock.php on line 1262
Warning: explode() expects parameter 2 to be string, array given in C:\Inetpub\barodsandperformancenew\serendipity\plugins\serendipity_event_forum\serendipity_event_forum.php on line 2400
Previously I had a whole page of errors but I then added $serendipity['production'] = true to the serendipity_config_local.inc.php file and now I am left with what is above.
2) I cannot get my CAPTCHA images to display using the spamblock plugin. I have checked the ttf files and the image files, all seem to be ok. I checked my gdlib.dll and that seems to be working also.
Here is the address to the forum: http://barodsandperformance.com/serendi ... age]=forum
Any help would be greatly appreciated. Thank you for your time!
Bill
Sorry to bug you all with these issues but I am losing my mind trying to resolve them. I have searched the forums and tried many fixes, but still have the same issues. Here is what I am struggling with:
1) I have installed the Forum plugin and when I try to add a comment or view a comment, I get the following error: Warning: explode() expects parameter 2 to be string, array given in C:\Inetpub\barodsandperformancenew\serendipity\plugins\serendipity_event_spamblock\serendipity_event_spamblock.php on line 1262
Warning: explode() expects parameter 2 to be string, array given in C:\Inetpub\barodsandperformancenew\serendipity\plugins\serendipity_event_forum\serendipity_event_forum.php on line 2400
Previously I had a whole page of errors but I then added $serendipity['production'] = true to the serendipity_config_local.inc.php file and now I am left with what is above.
2) I cannot get my CAPTCHA images to display using the spamblock plugin. I have checked the ttf files and the image files, all seem to be ok. I checked my gdlib.dll and that seems to be working also.
Here is the address to the forum: http://barodsandperformance.com/serendi ... age]=forum
Any help would be greatly appreciated. Thank you for your time!
Bill
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact:
Re: Forum plugin and CAPTCHA image issues
I cannot help you with the errors, but the missing captcha might be due to being a logged-in author?
=Don=
Re: Forum plugin and CAPTCHA image issues
Hi Don,
Thank you for the response. Unfortunately I tried posting from several different computers, several different browsers and as a guest user, all with the same result. The CAPTCHA image shows as a box with an X and the word CAPTCHA beside it. If you check the properties of the image location, this is the link it provides: http://barodsandperformance.com/serendi ... f9c066a0b2
If you have any other suggestions please let me know.
Thanks again!
Bill
Thank you for the response. Unfortunately I tried posting from several different computers, several different browsers and as a guest user, all with the same result. The CAPTCHA image shows as a box with an X and the word CAPTCHA beside it. If you check the properties of the image location, this is the link it provides: http://barodsandperformance.com/serendi ... f9c066a0b2
If you have any other suggestions please let me know.
Thanks again!
Bill
Re: Forum plugin and CAPTCHA image issues
Try to replace serendipity_event_forum.php on line 2400
with
or
and in serendipity_event_spamblock.php on line 1262
with
The missing CAPTCHA is an issue of PHP 5.4.x series, probably. It will work well with 5.3.x.
Beside that Captchas require the client's browser to accept cookies, and the server to properly utilize a PHP session storage, you will possibly fix that problem by downgrade or set the correct Imagick package, as PECL imagick 3.1 wrapper is still beta for PHP 5.4.4x and has to get allowed first before install:.
https://bugs.php.net/bug.php?id=61501
If it hasn't been finally released by now, the http://pecl.php.net/package/imagick/3.1.0RC2 package should compile well with PHP 5.4 now.
Code: Select all
$uri_parts = explode('?', str_replace('&', '&', $eventData));
Code: Select all
$uri_parts = explode('?', (string)str_replace('&', '&', $eventData));
Code: Select all
$theUri = (string)str_replace('&', '&', $eventData);
$uri_parts = explode('?', $theUri);
Code: Select all
$parts = explode('_', $eventData);
Code: Select all
$parts = explode('_', (string)$eventData);
Beside that Captchas require the client's browser to accept cookies, and the server to properly utilize a PHP session storage, you will possibly fix that problem by downgrade or set the correct Imagick package, as PECL imagick 3.1 wrapper is still beta for PHP 5.4.4x and has to get allowed first before install:
Code: Select all
$ pear config-set preferred_state beta
https://bugs.php.net/bug.php?id=61501
If it hasn't been finally released by now, the http://pecl.php.net/package/imagick/3.1.0RC2 package should compile well with PHP 5.4 now.
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
Ian, you ROCK!!! Your suggestion took care of the errors that I was receiving. I have not tackled the CAPTCHA issue yet, but I will post my results as soon as I do.
Thank you for your help!!
Bill
Thank you for your help!!
Bill
Re: Forum plugin and CAPTCHA image issues
Hi Bill
Fine, I fixed the forum (additional) and spamblock (core) plugins too.
You'll need to allow beta state... http://pecl.php.net/package/imagick
Fine, I fixed the forum (additional) and spamblock (core) plugins too.
You'll need to allow beta state... http://pecl.php.net/package/imagick
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
Ian,
I tried and tried to resolve the CAPTCHA issue, but had no luck. Instead I decided to use the ReCAPTCHA plugin which seems to be working well. Thank you again for the help with everything.
I am hoping that maybe you can help me with a similar issue. I am using the Self Registration plugin and it seems that it does not have the hooks needed to redirect the CAPTCHA option to the ReCAPTCHA. Everything else that has the CAPTCHA option has worked perfectly except this one. Is there a way to enable this plugin to use the ReCAPTCHA plugin? If so, would it be able to be a popup window since the sidebar does not really allow the space for the ReCAPTCHA image?
I do have a question not related to the CAPTCHA issue also. Does anyone know if it is possible to set up the User Self Registration plugin to allow people to only post items to the Event Forum plugin? I do not want anyone else other than myself to be able to post items to the News Blog, it would be ok if they comment on a news item, but I do not want them to be able to create, delete or modify news postings. If it is possible, would someone please let me know how?
Thank you for the help!!
http://www.barodsandperformance.com/serendipity
Bill
I tried and tried to resolve the CAPTCHA issue, but had no luck. Instead I decided to use the ReCAPTCHA plugin which seems to be working well. Thank you again for the help with everything.
I am hoping that maybe you can help me with a similar issue. I am using the Self Registration plugin and it seems that it does not have the hooks needed to redirect the CAPTCHA option to the ReCAPTCHA. Everything else that has the CAPTCHA option has worked perfectly except this one. Is there a way to enable this plugin to use the ReCAPTCHA plugin? If so, would it be able to be a popup window since the sidebar does not really allow the space for the ReCAPTCHA image?
I do have a question not related to the CAPTCHA issue also. Does anyone know if it is possible to set up the User Self Registration plugin to allow people to only post items to the Event Forum plugin? I do not want anyone else other than myself to be able to post items to the News Blog, it would be ok if they comment on a news item, but I do not want them to be able to create, delete or modify news postings. If it is possible, would someone please let me know how?
Thank you for the help!!
http://www.barodsandperformance.com/serendipity
Bill
Re: Forum plugin and CAPTCHA image issues
Hmm
For the last question, I would go into Administration Backend / "Group Management" and add a new group "Forum members". Include the members you have already-in and allow none of the checkboxes. This should do this, I presume... Maybe you also need to do this in "User Management". After then you should add the newly registered members to be in "Forum Members" only (if that is an option in the add-user plugin, please regard this to be a sophisticated guess).
I can't say anything how to set a re-captcha popup there at the moment, but why do you need to use captchas, since only working in already restricted areas?
Could you please explain what did not work, following the upper described PEAR beta allowance for the imagick PECL?
For the last question, I would go into Administration Backend / "Group Management" and add a new group "Forum members". Include the members you have already-in and allow none of the checkboxes. This should do this, I presume... Maybe you also need to do this in "User Management". After then you should add the newly registered members to be in "Forum Members" only (if that is an option in the add-user plugin, please regard this to be a sophisticated guess).
I can't say anything how to set a re-captcha popup there at the moment, but why do you need to use captchas, since only working in already restricted areas?
Could you please explain what did not work, following the upper described PEAR beta allowance for the imagick PECL?
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
Thanks Ian, I will try your suggestion with the User Management and see if that works.
The reason for the ReCAPTCHA when using the Self Registration plugin is to prevent account requests from non-humans. I have read many posts indicating this as an issue, but was resolved by using the CAPTCHAs. Since that doesn't work for me because of the PHP issue, I am hoping to use the ReCAPTCHA to take its place.
As for the PEAR and Imagick PECL...well apparently I am not smart enough to get PEAR installed and working. I did find someone who claimed to have the same issue and provided a dll file to replace the one I was using, but still did not work. Maybe it is because I am using Windows IIs 6.0 with PHP and FastCGI, but everything I tried with configurations and permissions, etc. just didn't work for me.
Thanks,
Bill
The reason for the ReCAPTCHA when using the Self Registration plugin is to prevent account requests from non-humans. I have read many posts indicating this as an issue, but was resolved by using the CAPTCHAs. Since that doesn't work for me because of the PHP issue, I am hoping to use the ReCAPTCHA to take its place.
As for the PEAR and Imagick PECL...well apparently I am not smart enough to get PEAR installed and working. I did find someone who claimed to have the same issue and provided a dll file to replace the one I was using, but still did not work. Maybe it is because I am using Windows IIs 6.0 with PHP and FastCGI, but everything I tried with configurations and permissions, etc. just didn't work for me.
Thanks,
Bill
Re: Forum plugin and CAPTCHA image issues
Ah I see. I didn't get you wanted the registerbox to display a CAPTCHA itself.
This should be already in, as far as I can see. You have to enable 'use Captcha' in the add User Plugin config, which is off by default.
If this still does not work taking the RE-Captcha instead, you should move the RE-Captcha Plugin before the addUser Plugin in your plugin list. This should run then, if Captcha is enabled in general in the spamblock event plugin.
Ah, yes, right! This Pear and in special that Imagick PECL thing is a little bit tricky on win systems. I do think a current xampp would allow that, but I am not sure. I myself am using an older one with a dropped-in PHP 5.4.14 and I have the same problem, but since this is locally development only, this does not really hurt me.
This should be already in, as far as I can see. You have to enable 'use Captcha' in the add User Plugin config, which is off by default.
If this still does not work taking the RE-Captcha instead, you should move the RE-Captcha Plugin before the addUser Plugin in your plugin list. This should run then, if Captcha is enabled in general in the spamblock event plugin.
Ah, yes, right! This Pear and in special that Imagick PECL thing is a little bit tricky on win systems. I do think a current xampp would allow that, but I am not sure. I myself am using an older one with a dropped-in PHP 5.4.14 and I have the same problem, but since this is locally development only, this does not really hurt me.
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
Well I checked that the ReCAPTCHA plugin is before the User Self Registration and that use CAPTCHAs is enabled all around, but I still get an error when trying to self register. The error states that the CAPTCHA was entered incorrectly, which makes a lot of sense since it never shows any place for you to enter the CAPTCHA or ReCAPTCHA. Any other things that I should try?
The whole PEAR thing just makes my head hurt...I am definitely no programmer.
Thank you for all the help, really appreciate it!!
Bill
The whole PEAR thing just makes my head hurt...I am definitely no programmer.
Thank you for all the help, really appreciate it!!
Bill
Re: Forum plugin and CAPTCHA image issues
After moving around, did you press the SAVE button to fix your plugin order movements?bdesanto wrote:Well I checked that the ReCAPTCHA plugin is before the User Self Registration and that use CAPTCHAs is enabled all around, but I still get an error when trying to self register.
Order (among others) should be RECAPTCHA, SPAMBLOCK, ADDUSER (I think - I'm not sure about the last two).
Yes and the sidebars and the subpage registerbox use different tokens..., which is kind of funny...?! Are there more than one instances of adduser and recaptcha Plugins installed?bdesanto wrote:The error states that the CAPTCHA was entered incorrectly, which makes a lot of sense since it never shows any place for you to enter the CAPTCHA or ReCAPTCHA.
Well if that all does not help, wie could try to remove recaptcha and disable captcha usage at all and install the Spam Bee Plugin via Spartacus (*) and place it/them right on top (in this order) in your event Plugin list. Then enable Spam Bee's Honeypot to YES, as Method JSON (I like this one, but this could also be 'default') and hidden CAPTCHAS to 'reject comments'.bdesanto wrote:Any other things that I should try?
bdesanto wrote:The whole PEAR thing just makes my head hurt...I am definitely no programmer.
Well yes, but you are serving the Web from a Windows Server, so this should be as secure as possible and well maintained, like every webserver (this includes things like correct pear settings)
(*) and eventually also the Spam Bayes Plugin, which I think you would not even need in that special case
Edit:
Could it be, that your template provides an loginbox.tpl and/or registerbox.tpl file, which is missing the essential hook? See:
https://github.com/s9y/additional_plugi ... ox.tpl#L39
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
I sure did. I tried re-ordering them as suggested and still no change.Timbalu wrote:After moving around, did you press the SAVE button to fix your plugin order movements?bdesanto wrote:Well I checked that the ReCAPTCHA plugin is before the User Self Registration and that use CAPTCHAs is enabled all around, but I still get an error when trying to self register.
Order (among others) should be RECAPTCHA, SPAMBLOCK, ADDUSER (I think - I'm not sure about the last two).
I double checked and no, there is only one instance of all installed plugins.Yes and the sidebars and the subpage registerbox use different tokens..., which is kind of funny...?! Are there more than one instances of adduser and recaptcha Plugins installed?bdesanto wrote:The error states that the CAPTCHA was entered incorrectly, which makes a lot of sense since it never shows any place for you to enter the CAPTCHA or ReCAPTCHA.
I am not familiar with these plugins. Do they offer the same type of protection that a ReCAPTCHA does? If yes, then maybe this will be the way to go.Well if that all does not help, wie could try to remove recaptcha and disable captcha usage at all and install the Spam Bee Plugin via Spartacus (*) and place it/them right on top (in this order) in your event Plugin list. Then enable Spam Bee's Honeypot to YES, as Method JSON (I like this one, but this could also be 'default') and hidden CAPTCHAS to 'reject comments'.bdesanto wrote:Any other things that I should try?
I have no doubt that you are correct, so I am going to have to learn PEAR...still makes my head hurt.bdesanto wrote:The whole PEAR thing just makes my head hurt...I am definitely no programmer.
Well yes, but you are serving the Web from a Windows Server, so this should be as secure as possible and well maintained, like every webserver (this includes things like correct pear settings)
I checked the template that I am using and it does have the hooks included so I do not understand why it is not working. I also changed to the default template and still no go. It shows the user self registration boxes, the info pertaining to it and the "Go" button but no CAPTCHA, ReCAPTCHA or image place holder. So very confusing.Edit:
Could it be, that your template provides an loginbox.tpl and/or registerbox.tpl file, which is missing the essential hook? See:
https://github.com/s9y/additional_plugi ... ox.tpl#L39
As always, thank you for all of your help and support!!
Bill
Re: Forum plugin and CAPTCHA image issues
Hi Bill
I can't make you a diff between math or text captchas and re-captcha, since I do not know how that Goggle thing works in deep. Anyway, since Grischa wrote this BEE Plugin, some people have used it with great success!
It may also be quite imaginable that RE-CAPTCHA also uses PECL Imagick package and that, as long this isn't solved, can not work either. Just like the spamblock CAPTCHA.
Last but not least, you can downgrade your PHP to a PHP 5.3.x version easily, which do well with the previous imagick packages, as long as this upper PHP >= 5.4.4 imagick package is still beta.
I can't make you a diff between math or text captchas and re-captcha, since I do not know how that Goggle thing works in deep. Anyway, since Grischa wrote this BEE Plugin, some people have used it with great success!
It may also be quite imaginable that RE-CAPTCHA also uses PECL Imagick package and that, as long this isn't solved, can not work either. Just like the spamblock CAPTCHA.
Last but not least, you can downgrade your PHP to a PHP 5.3.x version easily, which do well with the previous imagick packages, as long as this upper PHP >= 5.4.4 imagick package is still beta.
Regards,
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Ian
Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Re: Forum plugin and CAPTCHA image issues
Ian,
Thank you so much for all of your advice!! I will have to give the BEE plugin a try and see how that works.
I am pretty sure the ReCAPTCHA problem with the User Self Registration plugin is not PECL related because ReCAPTCHA works just fine for commenting. I think the issue is that there simply is not enough room in the sidebar to render the ReCAPTCHA image. I tried moving it to other locations, but it seems as if the Self Registration plugin may have specific sizing restraints set in its code. Is there any way to mod the code to display the ReCAPTCHA image, just for the User Self Registration plugin, in a separate window? Or is there a way to modify size restraints so that the image appears? I really am beginning to think that this is the whole issue.
Please let me know your thoughts.
Thanks again!!!
Bill
Thank you so much for all of your advice!! I will have to give the BEE plugin a try and see how that works.
I am pretty sure the ReCAPTCHA problem with the User Self Registration plugin is not PECL related because ReCAPTCHA works just fine for commenting. I think the issue is that there simply is not enough room in the sidebar to render the ReCAPTCHA image. I tried moving it to other locations, but it seems as if the Self Registration plugin may have specific sizing restraints set in its code. Is there any way to mod the code to display the ReCAPTCHA image, just for the User Self Registration plugin, in a separate window? Or is there a way to modify size restraints so that the image appears? I really am beginning to think that this is the whole issue.
Please let me know your thoughts.
Thanks again!!!
Bill