Pages:
Author

Topic: FaucetBOX.com Discussion - page 96. (Read 237001 times)

legendary
Activity: 2352
Merit: 1268
In Memory of Zepher
November 20, 2015, 02:20:46 AM
I tried to create a Faucet, but I have a little problem. I changed config.php and I uploaded the files. Then I tried to load index.php and then this error apeard:
PHP Parse error:  syntax error, unexpected '[' in /home/w18210/public_html/faucet/index.php on line 132

The 132th line is:
  58 => ["DELETE FROM `Faucetinabox_Settings` WHERE `name` IN ('captchme_public_key', 'captchme_private_key', 'captchme_authentication_key', 'reklamper_enabled')"],

Then I deleted the "[" and the "]".

The next error:
PHP Parse error:  syntax error, unexpected '[' in /home/w18210/public_html/faucet/index.php on line 1602

This is the 1602th line:
    $response = ["status" => 404];

What shell I do? Can you tell me what could be the problem?
I sent e-mails to FaucetBox support, but they didn't answered.

Thanks
Upgrade your PHP version to the latest build; it is out of date and I think causing that error. You could also replace the []s with array(), though this could leave your script open to security errors.
full member
Activity: 176
Merit: 100
November 20, 2015, 01:51:37 AM
@kazuldur:
1561-1572
Quote
if(!$connection_error && $response['version'] && $version < intval($response["version"])) {
                $page = str_replace('<:: version_check ::>', $new_version_template, $page);
                $changelog = '';
                foreach($response['changelog'] as $v => $changes) {
                    if(intval($v) > $version) {
                        $changelog .= "

Changes in r$v: $changes

";
                    }
                }
                $page = str_replace(array('<:: url ::>', '<:: version ::>', '<:: changelog ::>'), array($response['url'], $response['version'], $changelog), $page);
            } else {
                $page = str_replace('<:: version_check ::>', '', $page);
            }
full member
Activity: 168
Merit: 100
November 20, 2015, 01:16:21 AM
I tried to create a Faucet, but I have a little problem. I changed config.php and I uploaded the files. Then I tried to load index.php and then this error apeard:
PHP Parse error:  syntax error, unexpected '[' in /home/w18210/public_html/faucet/index.php on line 132

The 132th line is:
  58 => ["DELETE FROM `Faucetinabox_Settings` WHERE `name` IN ('captchme_public_key', 'captchme_private_key', 'captchme_authentication_key', 'reklamper_enabled')"],

Then I deleted the "[" and the "]".

The next error:
PHP Parse error:  syntax error, unexpected '[' in /home/w18210/public_html/faucet/index.php on line 1602

This is the 1602th line:
    $response = ["status" => 404];

What shell I do? Can you tell me what could be the problem?
I sent e-mails to FaucetBox support, but they didn't answered.

Thanks
What is your faucet link
legendary
Activity: 971
Merit: 1000
November 19, 2015, 04:39:41 PM
I get this error and I do not know what
Are they me hack?

Code:
PHP Warning:  stream_socket_client(): unable to connect to tcp://222.222.222.222:43

The IP I do not know if I should post it


That's definitely not a part of our Faucet in a BOX script. But 43 is Whois protocol, which don't really make sense if it's a hack. Did you modify the script yourself in any way except for modifying the error message?

You have reason is not an error in the script, is an external script to avoid scammers.
I didn't know that meant or if it was a problem of hacking, so asked, thank you.


In that case it makes sense it's using Whois, it's not a hack.
sr. member
Activity: 350
Merit: 250
November 19, 2015, 04:17:31 PM
I get this error and I do not know what
Are they me hack?

Code:
PHP Warning:  stream_socket_client(): unable to connect to tcp://222.222.222.222:43

The IP I do not know if I should post it


That's definitely not a part of our Faucet in a BOX script. But 43 is Whois protocol, which don't really make sense if it's a hack. Did you modify the script yourself in any way except for modifying the error message?

You have reason is not an error in the script, is an external script to avoid scammers.
I didn't know that meant or if it was a problem of hacking, so asked, thank you.
legendary
Activity: 971
Merit: 1000
November 19, 2015, 04:11:47 PM
I get this error and I do not know what
Are they me hack?

Code:
PHP Warning:  stream_socket_client(): unable to connect to tcp://222.222.222.222:43

The IP I do not know if I should post it


That's definitely not a part of our Faucet in a BOX script. But 43 is Whois protocol, which don't really make sense if it's a hack. Did you modify the script yourself in any way except for modifying the error message?

EDIT: 222.222.222.222 IP address on the other hand doesn't look nice though: https://www.virustotal.com/en/ip-address/222.222.222.222/information/

we need some details about traffic come from faucet list , because faucetbox .com is using https protocol , so all traffic come from faucet list is blank REFERER , so it is better if you provide us with some details about this traffic like how many and from which country , it may be in Stats page .

You can just change the URL you have on the list from http://yourfaucet.net to something like http://yourfaucet.net/?source=faucetbox and track that on your side.
sr. member
Activity: 350
Merit: 250
November 19, 2015, 03:47:38 PM
I get this error and I do not know what
Are they me hack?

Code:
PHP Warning:  stream_socket_client(): unable to connect to tcp://222.222.222.222:43

The IP I do not know if I should post it
sr. member
Activity: 350
Merit: 250
November 19, 2015, 12:25:40 PM
He forgot a ; at the end of line 2355. Add one of those and it should be fine.
Cheesy Thank you
legendary
Activity: 2352
Merit: 1268
In Memory of Zepher
November 19, 2015, 12:13:37 PM
He forgot a ; at the end of line 2355. Add one of those and it should be fine.
sr. member
Activity: 350
Merit: 250
November 19, 2015, 12:10:18 PM
I'd like a new stats feature which allow us to see what  countries make more claims, like a list of countries sorted by number of claims made.

You should use Google Analytics or something similar for that.

Hi Kazuldur, can you add some feature on faucet or on faucetbox account, which will show us , for how many user this current balance is enough.

It depends on too many factors, it can't be easily calculated. Specifically it depends on how you advertise your faucet and what kind of users visit it, which is something that FaucetBOX.com can't know.

yes thats right,now i got this error:
PHP Notice:  Array to string conversion in /home/greenbit/public_html/index.php on line 1566
[quote
Which version do you use? Did you modify index.php anyway? This error doesn't make sense on this line...
If you modified the script please tell me what's on line 1566 in your index.php file.

no,im using r56 version.

It still doesn't make sense, line 1566 in r56 only has a bracket in it. Can you send me lines 1560-1570 from your index.php?

Currently you have to do that in the code of your faucet. Checking the error code and changing $ret['html'] around line 2355 in index.php should work.
However I think that customizing error messages is quite a nice idea, we'll think about implementing this in next version.
I found it, but what change?
Thank you
Code:
} else {
                        if($data['unit'] == 'satoshi')
                            $data['paid'] = $ret['html'];
                        else
                            $data['paid'] = $ret['html_coin'];
                    }
                } else {

That's not it. This snippet handles successful payout, you want to catch error. You want to find this part (line numbers from r62 added):
Code:
2352                     }       
 2353                 } else {
 2354                     $data['error'] = $ret['html'];
 2355                 }
 2356                 if($ret['success'] || $fb->communication_error) {
and change it to something like this (not tested):
Code:
2352                     }
 2353                 } else {
 2354                     if($ret['message'] == "This faucet exceeded it's safety limits!") {
 2355                         $ret["html"] = "
YOUR CUSTOM MESSAGE HERE
"
 2356                     }   
 2357                     $data['error'] = $ret['html'];
 2358                 }   
 2359                 if($ret['success'] || $fb->communication_error) {
Thank you, it jumped me an error, the line is different from the original version

PHP Parse error:  syntax error, unexpected '}' in
full member
Activity: 235
Merit: 250
November 19, 2015, 11:31:14 AM
Kazuldur   took your advice ... it works ...
 to version 62


====================

who wrote about spending Statistics...... in my experience...I spent a day 5000 DOGEcoin....I gave 5 DOGEcoin every 600 min... 5% referral commission..... a month spent 10 USD = 75488.79 DOGE(course 19.11.2015).......  Wink It was a plus ... .. cost faucets.... earnings on advertising
full member
Activity: 176
Merit: 100
November 19, 2015, 09:57:30 AM
@kazuldur:
1561-1572
Quote
if(!$connection_error && $response['version'] && $version < intval($response["version"])) {
                $page = str_replace('<:: version_check ::>', $new_version_template, $page);
                $changelog = '';
                foreach($response['changelog'] as $v => $changes) {
                    if(intval($v) > $version) {
                        $changelog .= "

Changes in r$v: $changes

";
                    }
                }
                $page = str_replace(array('<:: url ::>', '<:: version ::>', '<:: changelog ::>'), array($response['url'], $response['version'], $changelog), $page);
            } else {
                $page = str_replace('<:: version_check ::>', '', $page);
            }
full member
Activity: 168
Merit: 100
November 19, 2015, 08:04:03 AM
It depends on too many factors, it can't be easily calculated. Specifically it depends on how you advertise your faucet and what kind of users visit it, which is something that FaucetBOX.com can't know.
You could probably calculate the average spending per day and divide that by the balance. That would show how many days the faucet could be funded for at current rates. You could then probably divide that by the average amount sent to see how many users it could send to on average. It would be somewhat inaccurate, though I think it's similar to what narawaj wants.
Yes I can calculate it by myself. But it was better, if I do not need to calculate.
legendary
Activity: 2352
Merit: 1268
In Memory of Zepher
November 19, 2015, 07:24:34 AM
It depends on too many factors, it can't be easily calculated. Specifically it depends on how you advertise your faucet and what kind of users visit it, which is something that FaucetBOX.com can't know.
You could probably calculate the average spending per day and divide that by the balance. That would show how many days the faucet could be funded for at current rates. You could then probably divide that by the average amount sent to see how many users it could send to on average. It would be somewhat inaccurate, though I think it's similar to what narawaj wants.

I'd like a new stats feature which allow us to see what  countries make more claims, like a list of countries sorted by number of claims made.
You could probably add this in yourself with an external API and some databases. It sounds like it would be fairly simple to code in.
legendary
Activity: 971
Merit: 1000
November 19, 2015, 07:06:06 AM
I'd like a new stats feature which allow us to see what  countries make more claims, like a list of countries sorted by number of claims made.

You should use Google Analytics or something similar for that.

Hi Kazuldur, can you add some feature on faucet or on faucetbox account, which will show us , for how many user this current balance is enough.

It depends on too many factors, it can't be easily calculated. Specifically it depends on how you advertise your faucet and what kind of users visit it, which is something that FaucetBOX.com can't know.

yes thats right,now i got this error:
PHP Notice:  Array to string conversion in /home/greenbit/public_html/index.php on line 1566
[quote
Which version do you use? Did you modify index.php anyway? This error doesn't make sense on this line...
If you modified the script please tell me what's on line 1566 in your index.php file.

no,im using r56 version.

It still doesn't make sense, line 1566 in r56 only has a bracket in it. Can you send me lines 1560-1570 from your index.php?

Currently you have to do that in the code of your faucet. Checking the error code and changing $ret['html'] around line 2355 in index.php should work.
However I think that customizing error messages is quite a nice idea, we'll think about implementing this in next version.
I found it, but what change?
Thank you
Code:
} else {
                        if($data['unit'] == 'satoshi')
                            $data['paid'] = $ret['html'];
                        else
                            $data['paid'] = $ret['html_coin'];
                    }
                } else {

That's not it. This snippet handles successful payout, you want to catch error. You want to find this part (line numbers from r62 added):
Code:
 2352                     }       
 2353                 } else {
 2354                     $data['error'] = $ret['html'];
 2355                 }
 2356                 if($ret['success'] || $fb->communication_error) {
and change it to something like this (not tested):
Code:
 2352                     }
 2353                 } else {
 2354                     if($ret['message'] == "This faucet exceeded it's safety limits!") {
 2355                         $ret["html"] = "
YOUR CUSTOM MESSAGE HERE
"
 2356                     }   
 2357                     $data['error'] = $ret['html'];
 2358                 }   
 2359                 if($ret['success'] || $fb->communication_error) {
full member
Activity: 182
Merit: 100
November 19, 2015, 05:49:34 AM
I'd like a new stats feature which allow us to see what  countries make more claims, like a list of countries sorted by number of claims made.
full member
Activity: 235
Merit: 250
November 19, 2015, 05:49:26 AM

Bad idea. The problem here is an CSRF protection introduced in r52 (or r51, I'm not sure) that also makes it harder for simple bots to raid the faucet. You should really try to find out why it doesn't work for you. At freecoin.in.ua the problem is a feedjit.com that for some dumb reason makes a test connection to the site in backgroud, which generates a new token that isn't updated in the form. Removing feedjit.com should be enough to fix this issue.


ok .. trys .. thanks for the advice .... write result
full member
Activity: 168
Merit: 100
November 19, 2015, 04:53:28 AM
Hi Kazuldur, can you add some feature on faucet or on faucetbox account, which will show us , for how many user this current balance is enough.
full member
Activity: 176
Merit: 100
November 19, 2015, 02:41:21 AM
yes thats right,now i got this error:
PHP Notice:  Array to string conversion in /home/greenbit/public_html/index.php on line 1566
[quote
Which version do you use? Did you modify index.php anyway? This error doesn't make sense on this line...
If you modified the script please tell me what's on line 1566 in your index.php file.

no,im using r56 version.
sr. member
Activity: 350
Merit: 250
November 18, 2015, 06:20:22 PM
Sorry, but in my settings I found new:
Send limits
Limits of how much this faucet can payout in a 30 minute window.

What is it? What a "30 minute window"?

How much your faucet can send in 30 minutes. For example if you set it to 0.001 BTC, that's how much the faucet will be able to spend between 12:00 and 12:30. The amount that faucet has spent resets every 30 minutes. If your faucet tries to spend more than that, API will return:

Code:
{"status": 450, "message": "This faucet exceeded it's safety limits!"}

We also plan adding email notifications to that and optional "paranoid mode" that will reset the API kay if the limit is hit.

It's meant to be a protection from hackers stealing all coins if they get the API key in their hands and mass attacks of bots.
It seems great to me! Is there any way to change that message?
For example
Code:
This site has a maximum of x satoshi every half an hour.

Currently you have to do that in the code of your faucet. Checking the error code and changing $ret['html'] around line 2355 in index.php should work.
However I think that customizing error messages is quite a nice idea, we'll think about implementing this in next version.
I found it, but what change?
Thank you
Code:
} else {
                        if($data['unit'] == 'satoshi')
                            $data['paid'] = $ret['html'];
                        else
                            $data['paid'] = $ret['html_coin'];
                    }
                } else {
Pages:
Jump to: