{"id":37000195,"url":"https://github.com/laravelchen/myflash","last_synced_at":"2026-01-14T00:01:41.284Z","repository":{"id":57012174,"uuid":"84720341","full_name":"LaravelChen/myflash","owner":"LaravelChen","description":"Flash Message For Laravel5","archived":false,"fork":false,"pushed_at":"2017-03-17T12:31:45.000Z","size":107,"stargazers_count":37,"open_issues_count":0,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-04T15:59:47.160Z","etag":null,"topics":["flash","laravel","php"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LaravelChen.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":"2017-03-12T11:27:49.000Z","updated_at":"2022-04-19T08:41:03.000Z","dependencies_parsed_at":"2022-08-21T15:10:35.101Z","dependency_job_id":null,"html_url":"https://github.com/LaravelChen/myflash","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/LaravelChen/myflash","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LaravelChen%2Fmyflash","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LaravelChen%2Fmyflash/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LaravelChen%2Fmyflash/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LaravelChen%2Fmyflash/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LaravelChen","download_url":"https://codeload.github.com/LaravelChen/myflash/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LaravelChen%2Fmyflash/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28406468,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-13T21:51:37.118Z","status":"ssl_error","status_checked_at":"2026-01-13T21:45:14.585Z","response_time":56,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["flash","laravel","php"],"created_at":"2026-01-14T00:01:40.368Z","updated_at":"2026-01-14T00:01:41.245Z","avatar_url":"https://github.com/LaravelChen.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Flash Message For Laravel5\n\n## 介绍\n\u003e 整个package采用了Laravel内置的```Illuminate\\Session\\Store```中的一次性请求flash函数.\n显示视图的方式有三种，图中可以看到.(**安装的时候最好开启vpn,因为给有人反映国内镜像好像安装不了,所以说用国外的composer的镜像吧!**)\n\n## 效果图\n![image](https://github.com/LaravelChen/myflash/raw/master/images/example.png)\n\n\n## 安装\n#### 使用composer安装\n```\ncomposer require laravelchen/myflash\n```\n#### 然后在```config/app.php```添加provider和alias\n```\n'providers' =\u003e [\n   LaravelChen\\MyFlash\\MyFlashProvider::class,\n   ];\n```\n```\n'aliases' =\u003e [\n    'MyFlash'=\u003eLaravelChen\\MyFlash\\MyFlash::class,\n];\n```\n\n## 用法\n#### 在redirect重定向之前添加falsh\n```\npublic function index()\n{\n    MyFlash::success('邮件已发!请查收邮件!');\n\n    return Redirect::home();\n}\n```\n#### 同时你也可以使用下面这种形式\n- MyFlash::success('邮件已发!请查收邮件!')\n- MyFlash::info('邮件已发!请查收邮件!')\n- MyFlash::error('邮件已发!请查收邮件!')\n- MyFlash::warning('邮件已发!请查收邮件!')\n\n#### 或者你可以使用```myflash()```这种辅助函数的形式\n- myflash('邮件已发!请查收邮件!')\n- myflash()-\u003esuccess('邮件已发!请查收邮件!')\n- myflash()-\u003einfo('邮件已发!请查收邮件!')\n- myflash()-\u003eerror('邮件已发!请查收邮件!')\n- myflash()-\u003ewarning('邮件已发!请查收邮件!')\n\n#### 最后在你的视图中添加```message```视图\n```\n@include('myflash::notification')\n或者\n@include('myflash::top-message')\n或者\n@include('myflash::bottom-message')\n```\n\n## 注意事项\n#### 请在你的视图中增加font-awesome和jquery\n```\n\u003clink href=\"//cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css\" rel=\"stylesheet\"\u003e\n\u003cscript src=\"//cdn.bootcss.com/jquery/2.1.0/jquery.min.js\"\u003e\u003c/script\u003e\n```\n\n## 例子\n```\n\u003c!DOCTYPE html\u003e\n\u003chtml\u003e\n\u003chead\u003e\n    \u003cmeta charset=\"utf-8\"\u003e\n    \u003cmeta http-equiv=\"X-UA-Compatible\" content=\"IE=edge\"\u003e\n    \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1\"\u003e\n    \u003ctitle\u003eLaravel\u003c/title\u003e\n    \u003clink href=\"//cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.min.css\" rel=\"stylesheet\"\u003e\n\u003c/head\u003e\n\u003cbody\u003e\n\u003ch1 class=\"text-center\"\u003eHello World\u003c/h1\u003e\n\u003cscript src=\"//cdn.bootcss.com/jquery/2.1.0/jquery.min.js\"\u003e\u003c/script\u003e\n@include('myflash::notification')\n\u003c/body\u003e\n\u003c/html\u003e\n```\n## 自定义\n#### 如果你想要自定义样式或者其他效果的话可以使用\n```\nphp artisan vendor:publish\n```\n##### 之后视图文件会出现在你的```resources/views/vendor/myflash```目录下\n\n\u003e 最后感谢mercuryseries和Jeffrey Way的package!\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaravelchen%2Fmyflash","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flaravelchen%2Fmyflash","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flaravelchen%2Fmyflash/lists"}