SeguirBlog where would that PHP code run? What does it have access to?
If you have an instance of the Eloquent model for Group
, you can do $group->namePlural
To use Flarum PHP models, you need your code to run as part of an extension. You can't load Flarum database helpers in a vanilla PHP script. You can't load them in a Laravel app either, as we use a custom stack.
If you are accessing the database from an external script, you will need to write all the code necessary to retrieve a database entry and display it. The value is stored on the groups
table in the columns with the same names. It's usually best for external script to rely on the REST API rather than use direct database access, because modifying the database directly bypasses all extensions which is usually not a good thing.