Faucet List With Timer
This would be a useful addition to the clickforcharity.net site so that users can get the most out of faucets, etc. Using a list site that is now gone, I found I could double the income for the time spent. It saves wasting time visiting sites that are not yet ready or forgetting to visit ones that are. Much more efficient.
- It’s a user-filled list of sites with a timer set for each one.
- No need to remember which ones are ready or having to keep lots of tabs open.
- Can set up a few with our reflinks to start with
- If users keep the page open, that will get us better site stats for the ad networks and advertisers.
- We can see which sites are most popular.
- Links will have clickforcharity in the http_referer header, so sites will see they are getting traffic from us.
There is a page set up on the site using a custom plug-in (now gone —Screenshot instead). It will only work properly for logged-in users, so I also need to find a way to make it only available to logged-in users. Maybe the existing YouZer plug-in can do that; I don’t want to install the Members plug-in just for that.
It’s on github
Purpose
The aim of this tool is to attract users to the site. They don’t need to be donating their income to our projects; just visiting the site is supporting as well.
- To give all users a way to increase their faucet and PTC, etc. income that doesn’t cost them anything.
- To help existing ClickForCharity members to be more efficient in their tasks.
- To increase site visits, which in turn gives us access to better income sources
- To advertise the system to the new users who are not clicking for charity.
Done:
- Ability to add their own links.
- Ability to remove entries.
To Do:
- Since writing the below items, the timers have stopped working altogether. Could be after upgrading the PHP version. See notes below this list.
- The plug-in also causes Gutenberg editor to give the error “Updating failed. The response is not a valid JSON response.” when saving with the shortcode entered. When I put in something else instead of [faucet_script], it is fine. The link may give some insight.
- Sites that are ready (timer) could go to the top of the list, and the button colour changes to indicate. Here is something that might do it.
- I noticed that timers tend to go slow on some web pages and need refreshing. The timer needs to be accurate. This might help. (I know it’s javascript but the principles might apply.)
- Ability to edit entries.
- Default entries when a new instance is created (i.e., a new user), i.e., we populate it with a few faucets with our referral links.
- Is it possible to make it so that each site only appears once in the database? The present system makes a new entry for each site that each user puts in. Most users will have mostly the same sites overall. I can see the database getting huge otherwise.
- Ideally it should just be a link as entered by the user—just a text string held in the database and made into a link rather than making a url that calls a PHP function on the server.
Notes
There appear to be syntax errors in the plug-in. phpcodechecker.com found some:
- Error: There is 1 more closing parenthesis ‘)’ found
This count is unaware if parenthesis are inside of a string - Error: There are 4 more closing curly braces ‘}’ found
This count is unaware if curly braces are inside of a string - PHP Syntax Check: Parse error: syntax error, unexpected ‘else’ (T_ELSE), expecting end of file in your code on line 96
}else{
extendsclass.com found no errors though, showing it is good to use more than one!
Files
I saved out as much as I could of two old sites that had something like what we needed before they closed. They might save some time (they might also waste some; it’s a gamble, I suppose!)
Changelog
2021-09-14: Log Started.
Incorporated PHP changes made by WPMUdev when imported to the test site on their server: “Note: I had to fix your Faucet List plugin as it was causing some issues on our hosting; the exact issue is that the plugin was using PHP short tags ‘<?= instead of <?php’ as our hosting doesn’t support the PHP short tags.”
2021-11-01 –
Fixed deletion of tables when plug-in is disabled and re-enabled.