theodo/roger-cms-bundle
RogerCmsBundle is a Symfony CMS bundle for adding editable pages and managed content to an application. It provides a lightweight admin interface for pages, menus, and reusable content blocks, helping teams manage site content without building custom CMS features.
Read this first: theodo/roger-cms-bundle is not a Laravel package. It is a Symfony2 bundle (a port of Radiant CMS), and it predates Laravel 4. There is no service provider, no config/roger-cms.php, and no php artisan commands. As a Laravel developer you will only touch this if you inherit a legacy Symfony 2.0/2.1 application that already depends on it — you cannot composer require it into a modern Laravel app, and you should not try to port it.
If you do inherit such a project, look at these files first, in this order:
composer.json — pin down the exact symfony/symfony constraint. Anything below 2.1 means the controller/request APIs are the pre-2.1 style ($this->get('request'), $this->render() with different signatures).DependencyInjection/TheodoRogerCmsExtension.php and Configuration.php — the config tree shows every knob (theodo_roger_cms: root key), including which entity classes and tag handlers are wired.Resources/config/*.yml|xml — service wiring for the page repository, renderer, and tag handlers. This tells you what is overridable.Entity/Page.php, Entity/PagePart.php, Entity/Layout.php, Entity/Snippet.php — the Radiant content model: a page tree, each page owning page parts, inheriting a layout, with snippets as shared fragments.<r:content />-style tags are resolved.First use case: register the bundle in app/AppKernel.php, import its routing in app/config/routing.yml, run php app/console doctrine:schema:update --force (this era predates Doctrine migrations), then build a three-page tree with one layout and render it through the bundle's catch-all front controller.
Page tree as the content model. Pages are Doctrine entities with a parent/child relation and a slug. URLs are resolved by walking the tree by slug path rather than by Symfony routes — the bundle typically exposes one catch-all route (/{slug} with a default) that hands off to a page-resolver service. Keep that route last in routing.yml so your real application routes win.
Layouts + page parts. A layout is the HTML shell containing tag placeholders; each editable region is a page part. Editors change page parts in the admin, developers change the layout. Treat layouts as code (version them), page parts as data (do not).
{# layout stored in the DB or in Resources/views — check which this build supports #}
<html><body>
<r:content part="body" />
<r:snippet name="footer" />
</body></html>
Snippets for reuse. Snippets are global named fragments referenced by tag, the Radiant equivalent of a partial. Prefer snippets over copy-pasted markup across layouts; they are the one place a non-developer can safely edit shared chrome.
Custom tags as the extension point. When you need dynamic content, implement a tag handler and register it as a tagged service. This is the idiomatic way to add "latest 5 posts" or a contact form into a page body without giving editors raw PHP. Keep handlers thin — resolve data via your own services, return a string or a rendered template.
Caching. There is no cache invalidation layer worth relying on. The pragmatic pattern is to render a page to a string, store it keyed by page id + updated timestamp, and purge on the Doctrine postUpdate/postPersist events for Page. Do not cache inside the tag handlers.
Admin integration. The bundle ships CRUD controllers and form types. Extend the form types rather than editing vendor code, and override templates by shadowing them under app/Resources/TheodoRogerCmsBundle/views/. Protect the admin routes behind a firewall in security.yml — assume the bundle's own access control is minimal.
each(), old-style constructors, and Doctrine annotations using the pre-@ORM namespace aliases. Running it on PHP 8 is a rewrite, not a config change. If you must keep it alive, pin PHP 5.6/7.0 in a container and freeze the dependency tree.Controller::render(), request access, and the getRequest() deprecation all changed mid-2.x. If you are on 2.1+, some controllers in this bundle may already be subtly wrong; check for $this->get('request') and $this->container->get(...) patterns before debugging your own code.php app/console config:dump-reference theodo_roger_cms (2.1+) or read Configuration.php directly.doctrine:schema:update --dump-sql before --force, every time; the page tree's self-referencing foreign key is easy to break on a partial update.app/cache. Editors who "don't see their change" usually need a cache clear — wire that into your publish action early.How can I help you explore Laravel packages today?