Bitcoin Forum
May 26, 2024, 12:26:43 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 3 4 5 6 7 8 9 10 [11]  All
  Print  
Author Topic: 〖ⓉⓊⓉⓄⓇⒾⒶⓁ〗 Stop Bots + Proxies From Using Your Faucet  (Read 18793 times)
kaytokeyos
Sr. Member
****
Offline Offline

Activity: 339
Merit: 250


View Profile
July 14, 2016, 12:48:31 AM
 #201

Quote
<?php>
include_once $_SERVER['DOCUMENT_ROOT'] . '/captcha/securimage.php';

$securimage = new Securimage();

if ($securimage->check($_POST['captcha_code']) == false) {
  // the code was incorrect
  // you should handle the error so that the form processor doesn't continue

  // or you can use the following code if there is no validation or you do not know how
  echo "I'm sorry but you have to answer the math question correctly!.<br /><br />";
  echo "Please go <a href='javascript:history.go(-1)'>back</a> and use a caculator.";
  exit;
}

?>

how about i change this script
echo "Please go <a href='javascript:history.go(-1)'>back</a> and use a caculator.";
to this
echo "Please go <a href='index.php'>back</a> and use a caculator.";

its ok?

if i use script above i got eror but if i change the link its work
alw1tt
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
July 20, 2016, 05:00:56 AM
Last edit: July 20, 2016, 05:13:27 AM by alw1tt
 #202

Everything in this tutorial is being used on my faucet. Check it out HERE to see it in action!



Step Four

In step four we will be adding a simple math question displayed as an image as a second captcha. Faucet users cannot claim their satoshi until the math question is solved.

Download PHP captcha HERE extract it and add the "captcha" folder to your root directory. If you don't trust that download you can find the original HERE, it will require some configuring though.

Now open your template file (ROOTDIRECTORY/faucet/templates/YOURTEMPLATE/index.php) paste the following code at the very top line above <!DOCTYPE html>:
Code:
<?php session_start(); ?>

Paste the following code where you would like the equation to appear
Code:
<img id="captcha" src="/captcha/securimage_show.php" alt="CAPTCHA Image" />
<br>
<a href="#" onclick="document.getElementById('captcha').src = '/captcha/securimage_show.php?' + Math.random(); return false">[ New Problem ]</a>
<br>
<br>
<input type="text" name="captcha_code" size="10" maxlength="6" />
<br>
<br>

Now you need to create a PHP document. I use a program called Notepad++, however any text editor will work. Create a new document, then paste in the following code:
Code:
<?php>
include_once $_SERVER['DOCUMENT_ROOT'] . '/captcha/securimage.php';

$securimage = new Securimage();

if ($securimage->check($_POST['captcha_code']) == false) {
  // the code was incorrect
  // you should handle the error so that the form processor doesn't continue

  // or you can use the following code if there is no validation or you do not know how
  echo "I'm sorry but you have to answer the math question correctly!.<br /><br />";
  echo "Please go <a href='javascript:history.go(-1)'>back</a> and use a caculator.";
  exit;
}

?>


Keep the document open. Open your faucet index page, it will most likely be index.php in your ROOTDIRECTORY. (Not the template index.php) Now press CTRL+A and select everything and copy it. Go back to the document you were just making and paste it on the very bottom, underneath the ?>  Now save the file as what ever you want, I called mine math.php.

Go back to your faucet template file (ROOTDIRECTORY/faucet/templates/YOURTEMPLATE/index.php) search for the following: <form method="POST" class="form-horizontal" role="form">
on that same line link your PHP file to it like so:
Code:
<form action="math.php" method="POST" class="form-horizontal" role="form">


About the Step 4... Why don't you just use:

Code:
include_once $_SERVER['DOCUMENT_ROOT'] . '/faucet/index.php';

Instead of select everything, copy it, go back to the document you were just making and paste it on the very bottom?


And there is a Problem!
After using this math script, the referral link become:
-- http://yoursite.com/faucet/math.php?r=1XX9xXXZ3XTXXX5kTXxXKCvxkiXNXxdGXN
Instead of:
-- http://yoursite.com/faucet/?r=1XX9xXXZ3XTXXX5kTXxXKCvxkiXNXxdGXN

How to fix it?
alfaboy23
Hero Member
*****
Offline Offline

Activity: 546
Merit: 500



View Profile
July 20, 2016, 06:57:35 AM
 #203

...

And there is a Problem!
After using this math script, the referral link become:
-- http://yoursite.com/faucet/math.php?r=1XX9xXXZ3XTXXX5kTXxXKCvxkiXNXxdGXN
Instead of:
-- http://yoursite.com/faucet/?r=1XX9xXXZ3XTXXX5kTXxXKCvxkiXNXxdGXN

How to fix it?

I've asked that a long time ago

I use the math captcha but there is a slight problem,
The referral becomes http://xfaucet.digi-eye.xyz/math.php/?r=address instead of the original http://xfaucet.digi-eye.xyz/?r=address

Notice the math.php appended on the original ref link? Is there a way to fix that?

But, still no answer, it seems that there is no fix for this.

Gifted
Hero Member
*****
Offline Offline

Activity: 504
Merit: 501



View Profile
July 20, 2016, 11:16:19 AM
 #204

use a <div> and closing </div>
alw1tt
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
July 20, 2016, 04:58:40 PM
 #205

There is always a fix...  Wink

Open your Template index.php

Replace:
Code:
<code><?php echo $data["reflink"]; ?></code>

with:
Code:
<code><?php echo str_replace("math.php","",$data["reflink"]); ?></code>

That's it!  Cool
Butord
Member
**
Offline Offline

Activity: 95
Merit: 10


View Profile
September 18, 2016, 11:56:01 AM
 #206

Is there a method to block certain btc address if I'm not using faucetbox script? Yjahnks
FaucetRank.com
Hero Member
*****
Offline Offline

Activity: 868
Merit: 500



View Profile WWW
September 18, 2016, 05:21:27 PM
 #207

Is there a method to block certain btc address if I'm not using faucetbox script? Yjahnks

Which script are you using 1st tell me. If you' are using xapo than I can help you easily. It's very easy to block email add or btc address.
…………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹……………

  ████
█ ████
█ ████
█ ████
█ ████ █
█ ████ █
█ ████ █
█ ████ █
█ ████ █
  ████ █
  ████ █
  ████ █
  ████
  ████
█ ████
█ ████
█ ████
█ ████ █
█ ████ █
█ ████ █
█ ████ █
█ ████ █
  ████ █
  ████ █
  ████ █
  ████
  .SCAMMERS.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
  .EXPOSED.
.
▄▄▄▄▄▄▄▄
  ████
█ ████
█ ████
█ ████
█ ████ █
█ ████ █
█ ████ █
█ ████ █
█ ████ █
  ████ █
  ████ █
  ████ █
  ████
Butord
Member
**
Offline Offline

Activity: 95
Merit: 10


View Profile
September 19, 2016, 07:11:57 AM
 #208

Is there a method to block certain btc address if I'm not using faucetbox script? Yjahnks

Which script are you using 1st tell me. If you' are using xapo than I can help you easily. It's very easy to block email add or btc address.
…………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹………………………₹₹₹……………
I'm using paytoshi script. Actually I've already have the code. Yje only problem is where to add it
pkhuba082
Newbie
*
Offline Offline

Activity: 39
Merit: 0


View Profile
July 08, 2017, 07:42:43 AM
Last edit: July 08, 2017, 08:02:48 AM by pkhuba082
 #209

Hi,

Thanks for your support and help

Can anyone help me how to implement this code in Wordpress site?



Thanks
Pages: « 1 2 3 4 5 6 7 8 9 10 [11]  All
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!