Go Back   Pligg Forum > Pligg Development > Pligg Mods
Reply
 
LinkBack Thread Tools Display Modes
  #11 (permalink)  
Old 01-18-2008, 06:06 AM
dollars5's Avatar
dollars5 dollars5 is offline
Pligg is my love :)
 
Join Date: Dec 2006
Location: India
Posts: 2,163
Downloads: 29
Uploads: 1
Thanks: 292
Thanked 267 Times in 178 Posts
With 9.9 - the reCAPTCHA is built in by default, also comes options to use Whitehat CAPTCHA, default Pligg CAPTCHA or simple Math equations for your users to solve.
Reply With Quote
Sponsored Links
Check out the New Modules at the Pligg Pro Shop.
  #12 (permalink)  
Old 01-18-2008, 08:46 AM
xiesi's Avatar
xiesi xiesi is offline
Send a message via MSN to xiesi
Constant Pligger
Pligg Version: 9.95
Pligg Template: yget + diy
 
Join Date: Jun 2007
Posts: 228
Downloads: 29
Uploads: 0
Thanks: 0
Thanked 2 Times in 2 Posts
I want have CAPTCHA for submit comments.
__________________
www.qelele.com齐乐乐
Reply With Quote
  #13 (permalink)  
Old 01-18-2008, 08:52 AM
jemens jemens is offline
New Pligger
 
Join Date: Sep 2006
Posts: 3
Downloads: 31
Uploads: 0
Thanks: 0
Thanked 0 Times in 0 Posts
Good...that's exactly what i needed......
Reply With Quote
  #14 (permalink)  
Old 01-18-2008, 09:33 AM
xiesi's Avatar
xiesi xiesi is offline
Send a message via MSN to xiesi
Constant Pligger
Pligg Version: 9.95
Pligg Template: yget + diy
 
Join Date: Jun 2007
Posts: 228
Downloads: 29
Uploads: 0
Thanks: 0
Thanked 2 Times in 2 Posts
I really want have a captcha mod for submit comments.anyone can help?
__________________
www.qelele.com齐乐乐
Reply With Quote
  #15 (permalink)  
Old 02-10-2008, 01:50 PM
ruptan ruptan is offline
Casual Pligger
Pligg Version: 9.9.0
Pligg Template: dafault
 
Join Date: Feb 2008
Posts: 46
Downloads: 14
Uploads: 0
Thanks: 11
Thanked 1 Time in 1 Post
Hi,
Thanks for putting the solution online but I have a question..I am using the recaptcha already for my registration process. Can I use the same for submitting the news? If so, should I use the same solution you provided?
Thanks in advance.

Quote:
Originally Posted by fhelik View Post
Ok these are the steps to get the Recaptcha in the submission page, so every user has to fill the captcha in order to continue with the submission. /

You will end up with something like this: (check the attachment)

(Before start you will need a Recaptcha keys, to get them go to recaptcha register and get the key, also download the recaptchalib.php from the same site and save it in your pligg base folder)

(Before we start make sure the User Registration Captcha is "true" under the admin, configuration, Captcha)

Step 1: open submit_step_2.tpl

Look for this:


HTML Code:
 <input type="submit" value="{#PLIGG_Visual_Submit2_Continue#}" class="submit" /> <input type="hidden" name="url" id="url" value="{$submit_url}" /> <input type="hidden" name="phase" value="2" /> <input type="hidden" name="randkey" value="{$randkey}" /> <input type="hidden" name="id" value="{$submit_id}" />
Right before that insert this( remember to change YOURPUBLICKEY for yours):

Code:
         {php} 		
			require_once('recaptchalib.php');
			$publickey = "YOURPUBLICKEY"; // you got this from the signup page
			echo recaptcha_get_html($publickey);
		{/php}
Now open submit.php

look for this:

PHP Code:
check_actions('do_submit1');
    
$main_smarty->display($the_template '/pligg.tpl');
}

// submit step 2 
right after insert this (remember to change YOUR PUBLIC AND SECRET):

PHP Code:
//captcha
if(enable_captcha == 'true') {
            
        require_once(
'recaptchalib.php');        
        
// Get a key from http://recaptcha.net/api/getkey
        
$publickey "YOURPUBLICKEY";
        
$privatekey "YOURPRIVATE";
        
        
# the response from reCAPTCHA
        
$resp null;
        
# the error code from reCAPTCHA, if any
        
$error null;
        
        
# was there a reCAPTCHA response?
        
if ($_POST["recaptcha_response_field"]) {
                
$resp recaptcha_check_answer ($privatekey,
                                                
$_SERVER["REMOTE_ADDR"],
                                                
$_POST["recaptcha_challenge_field"],
                                                
$_POST["recaptcha_response_field"]);
                
                if (
$resp->is_valid) {
                        echo 
"Succesfully verified that you are human.";
                } else {
                        
# set the error code so that we can display it
                        
$error $resp->error;

                }
        }    
            
        if (!
$resp->is_valid) { // if incorrect captcha code was entered
            
$main_smarty->assign('register_error_text'"badcode");
            
$main_smarty->display($the_template '/register_error.tpl');
            return;
        }
        
// fin capthca 
a little below look for this:

PHP Code:
}

// submit step 3 
and replace it with this: ( I just added one more } )

PHP Code:
}}

// submit step 3 
Before start make backup of these 2 files, in case you make a mistake.
I made this from a code I found there in pligg, plus the resources of Recaptcha.net and recaptcha group.

I hope this helps, and work, please leave a comment after installation.

I don't know what people are doing wrong, but for those here are the files. remember to do the backup of the 3 files before replace. NOTE i am using yget template on indipop.net

check the attachment for the files.

ok I hope it works for you guys. please post here if success
Reply With Quote
  #16 (permalink)  
Old 02-13-2008, 03:49 PM
lacasuela lacasuela is offline
Constant Pligger
Pligg Version: 9.9
Pligg Template: yget mod
 
Join Date: Oct 2007
Posts: 203
Downloads: 52
Uploads: 0
Thanks: 4
Thanked 3 Times in 2 Posts
edit: i'm sorry it was a misunderstood

Last edited by lacasuela : 02-13-2008 at 04:48 PM.
Reply With Quote
  #17 (permalink)  
Old 05-23-2008, 10:58 PM
PliggNZ PliggNZ is offline
New Pligger
 
Join Date: Apr 2008
Posts: 22
Downloads: 1
Uploads: 0
Thanks: 1
Thanked 1 Time in 1 Post
Quote:
Originally Posted by dollars5 View Post
With 9.9 - the reCAPTCHA is built in by default, also comes options to use Whitehat CAPTCHA, default Pligg CAPTCHA or simple Math equations for your users to solve.
I can only see this on registration. How can I enable it on news submission?
Reply With Quote
  #18 (permalink)  
Old 06-27-2008, 06:58 AM
gameradam
 
Posts: n/a
Downloads:
Uploads:
How do I add this for news submissions so that when submitting news you'll have to enter in a RECAPTCHA code.
Reply With Quote
  #19 (permalink)  
Old 06-28-2008, 08:44 PM
gameradam
 
Posts: n/a
Downloads:
Uploads:
Anyone?
Come on, this would really help fight spam.
Reply With Quote
  #20 (permalink)  
Old 06-28-2008, 08:58 PM
chuckroast's Avatar
chuckroast chuckroast is offline
Pligg Developer
Pligg Version: 9.9
Pligg Template: Summerfest
 
Join Date: Jun 2006
Location: PA
Posts: 2,144
Downloads: 48
Uploads: 19
Thanks: 158
Thanked 419 Times in 259 Posts
Quote:
Originally Posted by gameradam View Post
Anyone?
Come on, this would really help fight spam.
I suggest you read the entire thread... The solution has already been posted.
__________________
Visit PliggPro the official Pligg Mods & Template Shop!

Reply With Quote
Reply



Thread Tools
Display Modes
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Similar Threads
Thread Thread Starter Forum Replies Last Post
[Mod] Dodging SPAM with recaptcha ednet Pligg Mods 22 08-09-2008 01:48 PM
Request: reCAPTCHA elindbloom Suggestions 1 06-24-2007 09:02 PM


LinkBacks Enabled by vBSEO 3.0.0