A lightweight PHP-based task and reward platform where users can complete tasks, earn rewards, manage their wallet, use referrals, and request withdrawals.
Tenthis is a lightweight task-and-reward web application built with PHP and MySQL.
The project provides the basic building blocks for a rewards platform, including user authentication, referral tracking, task management, wallet functionality, withdrawals, and shortlink integrations.
It is designed primarily as a learning project and a foundation that can be extended with additional task providers, APIs, payment systems, fraud detection, and analytics.
- User registration
- Login and logout
- User profiles
- Password management
- Session-based authentication
- Browse available tasks
- View task details
- Complete tasks and receive rewards
- Task history
- Admin task management
- User wallet
- Reward tracking
- Wallet balance management
- Withdrawal requests
- Withdrawal history
- Referral links
- Referral tracking
- Referral validation
- Referral-based rewards
The project includes lightweight endpoints inside APIS/ for integrating external shortlink/task systems.
These endpoints can be extended to support:
- Task synchronization
- Task verification
- Completion callbacks
- Reward processing
- External API integrations
Important: External providers may have their own API, traffic, incentivization, and payout requirements. Review their terms before integrating them into a production deployment.
The admin area provides functionality for managing:
- Users
- Tasks
- Withdrawals
- Rewards
- Platform activity
| Technology | Purpose |
|---|---|
| PHP | Backend application |
| MySQL / MariaDB | Database |
| HTML / CSS | Frontend |
| JavaScript | Client-side interactions |
| Apache | Local/production web server |
| XAMPP / WAMP | Local development |
tenthis/
β
βββ gfkjkjer/
β βββ admin/ # Admin panel
β
βββ img/ # Images and assets
β
βββ php/ # Shared PHP files
β βββ connection.php # Database connection
β βββ function.php # Shared functions
β βββ ...
β
βββ APIS/ # API integrations
β
βββ .htaccess # Apache configuration
βββ index.php # Homepage
βββ login.php # Login
βββ signup.php # Registration
βββ logout.php # Logout
βββ profile.php # User profile
βββ refer.php # Referral system
βββ task_offer.php # Task listing
βββ view_task.php # Task details
βββ students_offer.php # Student offers
βββ short.php # Shortlink functionality
βββ long.php # Long-link handling
βββ withdraw.php # Withdrawal requests
βββ withdraw_history.php # Withdrawal history
βββ update_wallet.php # Wallet updates
βββ verify.php # Verification
βββ contact.php # Contact page
βββ feedback.php # Feedback
βββ history.php # User history
βββ script.js # JavaScript
βββ style_.css # Base styles
βββ style_light.css # Light theme
βββ style_dark.css # Dark theme
βββ userform.sql # Database schema
βββ README.md
Before installing Tenthis, make sure you have:
- PHP 7.4 or newer
- MySQL or MariaDB
- Apache or another PHP-compatible web server
- XAMPP, WAMP, Laragon, or equivalent local environment
- A web browser
For production, use a currently supported PHP version rather than an outdated PHP release.
git clone https://github.com/epic-piyush/tenthis.git
cd tenthisOr download the repository as a ZIP and extract it into your web server's document root.
For XAMPP:
- Start Apache
- Start MySQL
- Make sure PHP is working correctly
Place the project inside:
xampp/htdocs/
For example:
xampp/htdocs/tenthis/
Open phpMyAdmin and create a database.
For example:
tenthis
Then import:
userform.sql
You can also import it from the MySQL command line:
mysql -u root -p tenthis < userform.sqlOpen:
php/connection.php
and configure your database credentials.
Example:
$host = "localhost";
$username = "root";
$password = "";
$database = "tenthis";If you use the API integration, check:
APIS/connection.php
and configure it as required.
Never commit production database passwords, API keys, or other secrets to GitHub.
For XAMPP, open:
http://localhost/tenthis/
You should now see the Tenthis homepage.
Tenthis is currently a lightweight project and should be reviewed and hardened before being exposed to the public internet.
Important areas to review include:
- Prepared SQL statements
- Input validation
- Output escaping
- Password hashing
- Session security
- CSRF protection
- Authentication and authorization
- Admin access control
- Rate limiting
- Wallet/reward transaction integrity
- Withdrawal validation
- API authentication
- Webhook/postback verification
- Secret/API-key management
Use PHP's password hashing functions:
password_hash($password, PASSWORD_DEFAULT);and verify them with:
password_verify($password, $hash);Do not commit files containing:
Database passwords
API keys
API secrets
Private tokens
Production credentials
Use environment variables or another secure secret-management approach for production.
Because Tenthis handles user rewards and wallet balances, reward operations should be treated as financially sensitive operations.
A production implementation should ensure that:
Task completion
β
Server-side verification
β
Transaction validation
β
Reward credited
β
Ledger entry created
The browser should never be trusted to directly award itself money or rewards.
For external task/shortlink integrations, use provider-supported server-side verification or signed callbacks where available.
The APIS/ directory is intended as an integration layer for external services.
A recommended production flow is:
User
β
βΌ
Tenthis
β
β Start task
βΌ
External provider
β
β User completes task
βΌ
Provider verification
β
β Server-to-server callback
βΌ
Tenthis API
β
β Verify request
βΌ
Task marked completed
β
βΌ
Reward credited
API integrations currently is as the tenthis website is running in another tab it validates user by the stored cookies, you can make it as your own comfort
Avoid trusting client-side parameters such as:
?completed=true
as proof of task completion.
For local debugging, PHP errors can be enabled temporarily:
ini_set('display_errors', 1);
error_reporting(E_ALL);Do not leave detailed error output enabled on a production server.
Contributions are welcome.
git clone https://github.com/epic-piyush/tenthis.gitgit checkout -b feature/my-featureKeep changes focused and document any configuration or database changes.
git add .
git commit -m "Add my feature"git push origin feature/my-featureThen open a Pull Request.
If you find a bug or have a feature request, open an issue in the repository.
When reporting a bug, include:
- PHP version
- MySQL/MariaDB version
- Operating system
- Steps to reproduce
- Expected behavior
- Actual behavior
- Relevant error messages
Please do not post passwords, API keys, database credentials, or other secrets in issues.
This project is licensed under the MIT License.
See LICENSE for details.
Piyush
GitHub: @epic-piyush
Repository: epic-piyush/tenthis
If you find Tenthis useful or interesting:
- β Star the repository
- π Report bugs
- π‘ Suggest improvements
- π§ Submit pull requests
- π Use it as a learning project
Tenthis is a learning-focused project and should be security-audited and properly configured before being used for real-money production workloads.

