{"id":18929375,"url":"https://github.com/thecodingmachine/html.widgets.messageservice","last_synced_at":"2025-06-12T04:35:43.534Z","repository":{"id":5678045,"uuid":"6888004","full_name":"thecodingmachine/html.widgets.messageservice","owner":"thecodingmachine","description":"Use this package to display info/warning/error messages to the user on a web page. Using the SessionMessageService class, you register messages to be displayed. Using the MessageWidget class, you display the error messages in your templates.","archived":false,"fork":false,"pushed_at":"2022-12-01T16:13:10.000Z","size":46,"stargazers_count":0,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"4.0","last_synced_at":"2025-06-05T23:55:02.834Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"fengsp/pencil","license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thecodingmachine.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-11-27T17:47:31.000Z","updated_at":"2022-12-01T16:12:22.000Z","dependencies_parsed_at":"2023-01-13T13:39:31.255Z","dependency_job_id":null,"html_url":"https://github.com/thecodingmachine/html.widgets.messageservice","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/thecodingmachine/html.widgets.messageservice","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Fhtml.widgets.messageservice","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Fhtml.widgets.messageservice/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Fhtml.widgets.messageservice/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Fhtml.widgets.messageservice/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thecodingmachine","download_url":"https://codeload.github.com/thecodingmachine/html.widgets.messageservice/tar.gz/refs/heads/4.0","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thecodingmachine%2Fhtml.widgets.messageservice/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259398657,"owners_count":22851476,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-08T11:32:15.059Z","updated_at":"2025-06-12T04:35:43.509Z","avatar_url":"https://github.com/thecodingmachine.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# User Message Service\n\nThis service allows to implement user oriented messaging. It relies on a simple function that will add a message with a given level, and an HTML block that will render user's messages when the page is loaded.\n\n![Example](doc/img/example.png)\n\n## Using the Service\n\nWhen the package is installed, a block is added to the template's content. When rendered, this block will dump the messages that were stored into the session.\n\nAdd a message :\n\n```php\n$messageService-\u003esetMessage(\"User \u003cb\u003efoo bar\u003c/b\u003e has been successfully cerated\", UserMessageInterface::SUCCESS);\n```\n\nThe `UserMessageInterface` defines 4 types of message :\n\n * SUCCESS\n * INFO\n * WARNING\n * ERROR\n \nBy default, the message will be displayed in the header block. But you are free to insert this block anywhere.\n\nMore Information can be found here :\n\n * [Using the message service](doc/index.md)\n * [Advanced usage](doc/advanced.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodingmachine%2Fhtml.widgets.messageservice","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthecodingmachine%2Fhtml.widgets.messageservice","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthecodingmachine%2Fhtml.widgets.messageservice/lists"}