Folder Structure and Customization
Event Portal was designed so that people with basic PHP knowledge can read and change the sources. This page shows where everything lives.
Main folders
index.php front controller of the public website config.php database settings include/ shared classes (database, page controller, events, payments, AI) extensions/ one PHP file per public page (home, search, details, checkout...) templates/modern/ the design: template.html, assets/style.css, assets/app.js languages/ en.php, es.php - one interface text file per language categories/, locations/ text files with categories and places ADMIN/ administration panel advertisers_admin/ organizer panel users_admin/ attendee panel css/, js/ shared styles and scripts of the event form cron.php, sitemap.php scheduled tasks and XML sitemap
How a page is built
Every request goes through index.php. The page controller either loads a CMS page (?page=events) or an extension directly (?mod=details&id=5). The extension prints its HTML, and the template engine places it inside templates/modern/template.html together with the menu, footer and language switcher.
Changing the design
- Colors, logo and headline can be changed without code in Logo and branding.
- Layout and styles are in
templates/modern/template.htmlandtemplates/modern/assets/style.css. Colors are CSS variables at the top of the file. - A page's content is in its file in
extensions/. For exampleextensions/home.phpis the home page.
The admin panels
In the three panels every menu item is a file named category/action.php. The menu itself is defined in pages_structure.php of each panel. To add a page, create the file and add one line to that menu file. Styles for the panels are in ADMIN/assets/modules.css and advertisers_admin/css/extra.css.
Shared classes
| Class | Purpose |
|---|---|
DatabasePDO | Database access (MySQL through PDO) |
PageController, PageModel, TemplateEngine | Routing, pages and templates |
EventListing | Searching events, tickets, orders and coupons |
PaymentGateway | Stripe and PayPal payments |
The same classes and admin layout are used by our other scripts such as the Jobs Portal, which makes it possible to combine products in one site later.
After updating the script, keep your own config.php, the languages, uploaded_images and thumbnails folders, and any template changes you made.
Last updated