The MPADQ is a server-rendered PHP web application backed by a MySQL database. Before uploading any application files, make sure your hosting environment satisfies every item below. A standard LAMP or LEMP stack — Linux, Apache or Nginx, MySQL, and PHP — covers the full list of requirements.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/ijmeisner/einerlei/llms.txt
Use this file to discover all available pages before exploring further.
Technology Stack
PHP (Server-Side)
All page logic, session management, and database interaction is handled in PHP. The MySQLi extension and native session support must both be enabled. The
mail() function is used for license key delivery emails, and curl is required for PayPal IPN validation.MySQL (Database)
All tables use the InnoDB storage engine for foreign-key enforcement. The application expects a database named
Quiz. See Database Setup for the full schema.Frontend
Pages are rendered as HTML5 with CSS3 styling. jQuery 1.12.2 is bundled at
src/jquery-1.12.2.min.js — no CDN dependency is required.Web Server
Apache or Nginx with PHP support. A standard LAMP or LEMP stack is the recommended setup. No special modules beyond standard PHP support are required.
Required PHP Extensions
The following PHP extensions must be enabled before deploying the application:| Extension | Purpose |
|---|---|
mysqli | Database connections throughout the application |
Sessions (session_start) | User authentication and quiz state across pages |
mail() | Sending license key delivery emails to purchasers |
curl | Posting back to PayPal for IPN validation |
Session Timeout
The application enforces a server-side session timeout controlled by a single variable insrc/timeout.php:
1800 seconds (30 minutes) is applied across every page that requires an authenticated session. Adjust this value before going live if your deployment requires a shorter or longer idle timeout.
File System Write Permissions
The PHP process must have write access to the following paths. Most are used for debug logging or CSV data exports; without write permission the relevant features will silently fail or produce errors.| Path | Purpose |
|---|---|
admin/dashboard/data-view/view-1/View1.csv | CSV export — respondent data view 1 |
admin/dashboard/data-view/view-2/View2.csv | CSV export — respondent data view 2 |
demographics/output.mysql | Debug log for demographic submissions |
likert/output.mysql | Debug log for Likert answer submissions |
finish/debug.txt | Debug log for score calculation |
purchaseSuccessful/ipn.log | PayPal IPN request/response log |
www-data on Debian/Ubuntu, apache on RHEL/CentOS):
Database Credentials File
Database credentials are stored insrc/login.php. This file is not distributed with the application source and must be created manually on the server after deployment.
The format expected by the application is:
$host, $user, $pass, and $dtbs are referenced directly throughout the application via require_once. Do not rename them.
Pre-Deployment Checklist
Work through these steps in order before uploading your application files.Provision a LAMP or LEMP Server
Confirm your hosting environment runs Linux with Apache or Nginx and has PHP available. A shared host, VPS, or cloud instance running Ubuntu 20.04+ or equivalent is suitable.
Enable Required PHP Extensions
Verify that
mysqli, session, mail, and curl are all active. Run php -m | grep -E 'mysqli|curl' on the server or check your host’s PHP configuration panel.Create the Quiz Database
Log in to MySQL and create the
Quiz database. See Database Setup for the full schema and script execution order.Create src/login.php
Create
src/login.php on the server with your database credentials as shown above. Confirm the file is excluded from version control.Set Write Permissions
Grant write access to the six paths listed in the File System Write Permissions section above.
Configure Session Timeout
Review the
$timeout value in src/timeout.php and adjust it to match your institution’s session policy.Configure PayPal IPN
Set the IPN notification URL in your PayPal account to point to
purchaseSuccessful/authenticate_ipn.php over HTTPS. See PayPal Integration for full details.