Apps
Building Basehim apps: the manifest and lifecycle, hooks, the App API, admin screens, AJAX actions, permissions, content types and blocks.
24 articles
-
App development best practices
The complete best-practice guide for building Basehim apps: structure, manifest, boot(), lifecycle and migrations, permissions, data, security, admin UI, AJAX, public routes, uploads and media, scheduled work, widgets, tables, hooks, MCP tools, performance, testing, packaging and a pre-release checklist.
-
Dashboard widgets
Add cards to the admin dashboard from your app: stats, lists, tables, charts, feeds and status checks drawn by core from the data you return, with settings, actions, caching, per-user layouts and permission checks on the server.
-
When an app fails: fault isolation and recovery
How Basehim keeps one broken app from taking a site down: code checked before it is loaded, failures contained while it starts, the app switched off with a report for the administrator, and a validated way to turn it back on.
-
Public routes for apps
Give your app public pages and endpoints with $this->router()->site(): every HTTP method, parameters, named URLs, per-route sign-in, permissions, CSRF and rate limits, and pages rendered inside the active theme, without ever overriding core's own URLs.
-
Import an RSS feed on a schedule
A step-by-step tutorial. Build an app that checks an RSS feed every hour and saves new items as draft posts, using scheduled tasks, outbound HTTP, terms, declared permissions and the app log, plus a real cron job for punctual runs.
-
Add a "Was this helpful?" widget with AJAX
A step-by-step tutorial. Build an app that asks readers whether a post helped, records answers through a rate-limited public AJAX action, stores them in its own table and shows a report to editors.
-
Build your first app: an announcement bar
A step-by-step tutorial. Build a small Basehim app with a settings screen in the admin and a message bar on every public page, and learn the manifest, boot(), admin routes, CSRF, settings, views and front-end output along the way.
-
Content types, blocks and widgets
Register your own content types, with admin screens and, since 1.2.94, public pages, taxonomies and custom fields; add custom blocks to the editor with a PHP renderer for the public site; and provide widgets for widget areas, the editor and the dashboard.
-
App permissions
How an app declares what it will touch, how site owners approve it, what happens when a call isn't allowed, the full permission catalogue, logs and the static scanner - and what the model does not protect against.
-
AJAX actions
Register browser actions with $this->ajax() and call them with Basehim.ajax. Core checks the session, CSRF token, capability, input schema and rate limit before your handler runs. Includes the full option and error reference.