1. Server requirements
Offerwall Ad is designed for ordinary PHP/MySQL hosting, including cPanel shared hosting.
| Requirement | Minimum / recommended | Why it is needed |
|---|---|---|
| PHP | 7.4 minimum 8.1–8.4 recommended | Application runtime. |
| MySQL / MariaDB | InnoDB + utf8mb4 | Users, offers, conversions, accounting, postbacks and logs. |
| PHP extensions | mysqli, curl, mbstring, openssl, fileinfo, json | Database, APIs, encryption, uploads and Unicode handling. |
| Apache rewrite | mod_rewrite + .htaccess | Clean URLs such as /register and /publisher/postbacks. |
| HTTPS | Required for production | Secure login cookies, provider callbacks, payments and webhooks. |
| ImageMagick | Optional, recommended | Automatic image compression, campaign thumbnails and favicon size generation. |
| PHP memory | 256 MB recommended | Catalog imports and image processing. |
| Upload size | 10 MB recommended | Logo/favicon/campaign uploads; application limits are lower than this. |
memory_limit=256M, upload_max_filesize=10M, post_max_size=12M, max_execution_time=120.2. Quick start
Upload the contents of the package to your domain's document root, for example public_html/. Make sure hidden files such as .htaccess are included.
Create a new, empty database and database user. Grant the user ALL PRIVILEGES on that database.
Issue/enable an SSL certificate and confirm your domain opens at https://....
Visit https://your-domain.com/install.php. The installer performs a server preflight before changing anything.
Enter the database credentials, final application URL, timezone, and first superadmin account.
Configure the scheduled tasks listed later in this guide. These power publisher postbacks, email delivery, network synchronization and maintenance.
Set branding, email, payments, CPA networks, postbacks and other platform settings.
3. cPanel installation walkthrough
Upload the files
- Open cPanel → File Manager.
- Open your target folder, usually
public_html. - Upload the ZIP package.
- Extract it inside the target folder.
- Confirm
install.php,.htaccess,database/,includes/,admin/, andcron/exist.
.htaccess is missing, extensionless/SEO-friendly routes may return 404 errors. In File Manager, enable “Show Hidden Files (dotfiles)” if necessary.Create the database
- Open cPanel → MySQL Databases or Database Wizard.
- Create a database.
- Create a database user with a strong random password.
- Add that user to the database.
- Grant ALL PRIVILEGES.
cPanel frequently prefixes both values. If your cPanel account is john, you may see:
Use the complete prefixed names in the installer.
Select PHP version/extensions
Depending on the host, open MultiPHP Manager, Select PHP Version, or PHP Extensions. Enable at least:
4. File and directory permissions
Do not make the entire script world-writable. Normal permissions are sufficient on most cPanel servers.
| Path | Recommended | Notes |
|---|---|---|
| Folders | 755 | Normal application directories. |
| PHP/CSS/JS files | 644 | Normal application files. |
config.php | 600 or 640 | Contains database credentials and application encryption key. |
/uploads | 755, writable by PHP | Stores branding and campaign/offer uploads. |
config.php or /uploads, correct ownership/hosting permissions instead.5. Using install.php
The web installer performs the following tasks:
- Checks PHP version and required extensions.
- Checks
database/schema.sqland application write access. - Connects to MySQL/MariaDB using the supplied credentials.
- Refuses to modify databases that already contain user data.
- Imports the full fresh-install database schema and starter Help Center content.
- Creates your first verified superadmin account.
- Generates a 256-bit application encryption key.
- Generates the cron authentication key.
- Creates upload directories.
- Writes
config.phpand automatically locks the installer.
install.php. Use https://example.com or, for a subdirectory install, https://example.com/network.6. Cron jobs
Open cPanel → Cron Jobs. The absolute path will vary by hosting account. A typical root looks like /home/USERNAME/public_html.
| Schedule | Script | Purpose |
|---|---|---|
| Every 5 minutes | deliver-webhooks.php | Publisher S2S postback delivery and retries. |
| Every 5 minutes | send-email.php | Sends queued lifecycle/support/account email. |
| Every 15 minutes | sync-networks.php | Synchronizes active CPA network offer catalogs. |
| Hourly | lifecycle.php | Lifecycle rules, promotions and support auto-close processing. |
| Hourly | maintenance.php | Log retention, history cleanup and campaign maintenance. |
| Daily | score-quality.php | Traffic Quality and Advertiser Trust scoring. |
Example commands:
/usr/local/bin/php is common but not universal. Your host may provide another binary such as an EasyApache version-specific PHP path. Ask the host or check cPanel documentation if the command fails.HTTP cron fallback
The cron scripts can be called over HTTPS using the generated cron key, but CLI cron is preferred because the key does not travel through web access logs.
cron_key setting in the database/admin configuration.7. Email and SMTP
Open Admin → Settings and configure the sender address and SMTP details if your hosting environment supports the included PHPMailer integration.
- Use an address on your domain, such as
noreply@example.com. - Set SPF, DKIM and DMARC in DNS for good delivery.
- Use the email queue cron job.
- Test password-reset and lifecycle email before launch.
includes/phpmailer/src/, the script falls back to PHP's mail() function. SMTP configuration specifically requires PHPMailer.8. Logo, favicon and image processing
In Admin → Settings, upload the site logo and favicon. Advertisers can upload campaign images while creating campaigns, and admins can replace offer/campaign images from the record editor.
Campaign images
Uploaded campaign images are optimized and derivative thumbnails are generated for card and square placements when ImageMagick is available. The original application image URL remains the source reference; offerwall/cards use the generated thumbnail when available.
9. Adding CPA networks
Open Admin → Networks. The script includes built-in support/presets for the original networks and also supports an unlimited number of Generic JSON Offer API networks.
Built-in networks
- Adscend Media
- CPAlead
- CPX Research
Custom networks
For a generic network you can configure API URL, GET/POST method, credentials, credential placement, pagination, response path, field mappings, click/SubID parameters and conversion/reversal statuses.
Enter a unique slug/name and choose the Generic JSON adapter.
Use query, header, POST body, Bearer token, or Basic Auth based on the provider's documentation.
Map ID, title, payout, destination URL, countries, devices, categories, status, EPC and other supported values.
Map the provider's transaction ID, click/SubID, payout and status macros to the generated Offerwall Ad receiver.
Use Test Connection, run a manual offer sync and use the provider's postback tester before production traffic.
10. Payment providers
Payment credentials are configured in Admin → Settings. Never place live API secrets in frontend JavaScript or public files.
| Provider | Callback / notes |
|---|---|
| PayPal | Webhook: https://YOUR-DOMAIN/webhooks/paypal. Configure Client ID, Client Secret and Webhook ID. |
| Square / Cash App Pay | Webhook: https://YOUR-DOMAIN/webhooks/square. Configure Application ID, Location ID, access token and webhook signature key. |
| NOWPayments | IPN: https://YOUR-DOMAIN/webhooks/nowpayments. Configure API key and IPN secret. |
| Zelle | Manual reconciliation through the admin deposit workflow. |
11. Postbacks and webhooks
Publisher postbacks
Publishers manage their S2S callbacks at /publisher/postbacks. The system supports GET, form POST and JSON delivery, callback passwords, HMAC signatures, test delivery, delivery logs and retries.
Integration presets are available at /publisher/postbacks/integrations, including EvolutionScript, PTC Pro, TonaPTC, Pocket GPT Script, Garnetly, Generic PHP/MySQL GPT, Generic Laravel Rewards and Generic WordPress Rewards.
Advertiser/direct campaign postback
Each direct campaign provides a campaign-specific secret and advertiser postback URL under /campaigns/{ID}/edit. The advertiser must preserve the click_id sent with traffic and return it server-to-server when the conversion occurs.
CPA network inbound postbacks
Built-in and custom networks have receiver URLs configured in Admin → Networks. The receiver validates the network secret/key and attributes the transaction to the original click before crediting money.
12. Cloudflare, CDN and reverse proxy notes
- Use Full (strict) SSL when possible.
- Do not cache authenticated dashboard/admin pages.
- Do not cache postback, webhook, API or cron endpoints.
- Hosted offerwalls use visitor/device-specific output; avoid forcing edge caching on
/wall/*. - Allow your payment/network providers to reach webhook and postback endpoints.
- If security rules block legitimate callbacks, create narrow endpoint exceptions rather than disabling protection site-wide.
13. Production security checklist
- Use HTTPS and redirect HTTP traffic to HTTPS.
- Keep
debug=falsein production. - Keep
config.phpoutside public download access and permissions restrictive. - Use a unique superadmin password and a unique database password.
- Never publish CPA API keys, postback secrets, callback passwords or payment secrets.
- Configure provider signature verification and use their test/sandbox tools.
- Keep
/uploads/.htaccessin place so executable PHP-like files cannot run from uploads. - Use an empty database for new installs; never rerun the installer over production data.
- Back up both the database and uploaded images before updates.
- Review Admin → Audit and Admin → System regularly.
- Test fraud holds, conversion reversals, payout rejection/refunds and campaign escrow before launch.
- Keep the OS/web server/PHP/MySQL patched.
14. Backups and updates
What to back up
- The complete MySQL/MariaDB database.
config.php./uploads.- Any manually installed PHPMailer files or custom provider integration code.
Before updating
- Put the site into a maintenance window if the update changes database/accounting code.
- Create a full database backup.
- Create a file backup.
- Read the release notes.
- Run only the migrations included for that version, if any.
- Do not overwrite your live
config.phpwith an example config. - Test login, offerwall, conversion, postbacks, payouts and deposits after updating.
15. Troubleshooting
Use the full cPanel-prefixed database name/username, confirm the password, ensure the database user was assigned to that database with ALL PRIVILEGES, and usually use localhost as host.
Use a new empty database. Only use “Resume a partial fresh installation” if a previous install attempt created tables and there are no users. The installer refuses databases with existing user data.
Check file ownership and root directory permissions. Temporarily give the PHP/web-server user write access to the application root. Do not permanently use 777.
Confirm the included .htaccess exists and Apache mod_rewrite/AllowOverride is enabled. On cPanel Apache hosting this is usually automatic.
Confirm fileinfo is enabled, /uploads is writable, and PHP upload_max_filesize/post_max_size are large enough.
ImageMagick is optional. Ask the host to enable/install ImageMagick/Convert. The script still stores the original upload when ImageMagick is unavailable.
Confirm the send-email.php cron runs. If using SMTP, make sure PHPMailer exists under includes/phpmailer/src/ and the SMTP credentials are correct. Also verify SPF/DKIM/DMARC.
Verify cron/deliver-webhooks.php is scheduled and the endpoint is public HTTPS. Check publisher/admin delivery logs for HTTP status and response errors.
Check the network is Active, run Test Connection/Sync Offers in Admin → Networks, confirm the credentials/field mappings, and verify the sync-networks.php cron.
Check the secret/key, HTTPS certificate, Cloudflare/WAF rules, provider macro names and that the callback URL is copied exactly from the admin interface.
Temporarily check your hosting PHP error log. Common causes are a missing required extension, incompatible PHP version, missing files after ZIP extraction or incorrect filesystem ownership.
Hard-refresh the browser and purge any CDN/Cloudflare cache. Do not aggressively cache authenticated PHP pages.
Launch checklist
- Installer finished and superadmin login works.
- HTTPS works with no certificate warnings.
- Admin branding/logo/favicon configured.
- Email sending tested.
- All cron jobs running.
- At least one CPA network connection and offer sync tested.
- Inbound conversion postback tested.
- Publisher S2S postback tester passed.
- Advertiser campaign postback tested.
- Deposit sandbox test completed without duplicate credit.
- Payout request/reject/paid accounting tested.
- Database and files backed up.
Do not accept production deposits or large traffic volumes until the full conversion and payment lifecycle has been tested with your own live provider credentials/settings.