AI blog · DotApp PHP Framework 2.0
Návody pre ľudí aj pre kódujúcich agentov
Complete walkthroughs with copy-paste code: modules, config.php, cache, DSM, secure forms, Bridge, and .js. Each article is its own URL so agents can retrieve one topic at a time.
Aplikácia a moduly
How to create a module in DotApp PHP Framework
Scaffold a module with DotApper, register routes in initialize(), and ship Config::module fallbacks so the module stays portable.
Čítať článokHow app/config.php works in DotApp PHP Framework
One file configures the app and every module: databases, drivers, secrets, and Config::module overrides without editing module folders.
Čítať článokHow module initialization works in DotApp PHP Framework
Boot order from index.php through listeners, initializeCondition, initialize(), and lazy loading with initializeRoutes().
Čítať článok
Cache a session
How to use cache in DotApp PHP Framework
Cache::use, save and load, File Redis Memcached and Null drivers, context keys, TTL, and the return value of a miss.
Čítať článokHow to use sessions in DotApp PHP Framework (DSM)
Application state belongs in DSM::use(Module), never in $_SESSION. Drivers, reserved keys, and config.php registration.
Čítať článok
Bezpečný kanál prehliadača
How DotApp PHP Framework protects the browser-to-PHP channel
Per-session keys, encrypted transport, formName binding, integrity checks, and encrypted identifiers — why a lone CSRF token is a narrow guarantee.
Čítať článokHow to create secure forms in DotApp PHP Framework
fo-rm, formName between the tags, crcCheck, and $request->form() with a complete copy-paste module example.
Čítať článokSecure backend-frontend communication in DotApp PHP Framework
When to use fo-rm, $dotapp().load(), Bridge, or uploadFile. PHP still checks rights after a successful crcCheck.
Čítať článok
Dáta a HTTP
How to use the database in DotApp PHP Framework
DB::module RAW query builder, shop_items table naming, all first execute, transactions, and pagination.
Čítať článokHow routing works in DotApp PHP Framework
Router::get and post, STATIC_ROUTE, path constraints, callable strings, before hooks, and JSON endpoints.
Čítať článokHow to render views and layouts in DotApp PHP Framework
Renderer::new, view and layout files, {{ var: }} directives, silent empty output, assets, and translations.
Čítať článokHow authentication and 2FA work in DotApp PHP Framework
Auth::login return shapes, stages, Auth::can, TOTP, and $dotapp().twoFactor. Auth::logged() does not exist.
Čítať článokHow to create database migrations with Installation.php in DotApp PHP Framework
Versioned Installation.php, alreadyDone and markDone, uninstallers. DB::migrate() is not implemented.
Čítať článok
JavaScript a Bridge
How to build AJAX lists with pagination in DotApp PHP Framework
paginate() plus $dotapp().load(), overlay, live DOM patch, encrypted ids. No full-page ?page= reloads.
Čítať článokHow to call PHP from JavaScript with DotBridge
Bridge::listen, $dotApp->bridge->fn, template on(click), filters, and rate limits on the same secure channel.
Čítať článokCallable strings in DotApp PHP Framework
Module:Class@method!, # middleware, * models, when to skip DI, and DotApp::call().
Čítať článokHow to use $dotapp() JavaScript in DotApp PHP Framework
Mandatory /assets/dotapp/dotapp.js, boot events, selectors, live(), parseReply(), and preloaders.
Čítať článokReactivity in DotApp PHP Framework
dotapp.reactive.js: variable, databind, computed, reactive-api attributes, and the PHP Reactive helper.
Čítať článok