{"id":22604171,"url":"https://github.com/shinshin86/bottle-flash2","last_synced_at":"2025-04-11T03:44:04.121Z","repository":{"id":14911321,"uuid":"77305519","full_name":"shinshin86/bottle-flash2","owner":"shinshin86","description":"Bottle-Flash2 is a fork of Bottle-Flash. Flash plugin for bottle.","archived":false,"fork":false,"pushed_at":"2022-02-19T22:06:50.000Z","size":11,"stargazers_count":3,"open_issues_count":1,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-25T01:51:10.286Z","etag":null,"topics":["bottle","flash"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/shinshin86.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-12-25T01:05:10.000Z","updated_at":"2022-02-19T22:06:53.000Z","dependencies_parsed_at":"2022-07-22T09:32:37.958Z","dependency_job_id":null,"html_url":"https://github.com/shinshin86/bottle-flash2","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinshin86%2Fbottle-flash2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinshin86%2Fbottle-flash2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinshin86%2Fbottle-flash2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/shinshin86%2Fbottle-flash2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/shinshin86","download_url":"https://codeload.github.com/shinshin86/bottle-flash2/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248281415,"owners_count":21077423,"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":["bottle","flash"],"created_at":"2024-12-08T13:08:33.842Z","updated_at":"2025-04-11T03:44:04.100Z","avatar_url":"https://github.com/shinshin86.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bottle-Flash2\nflash plugin for bottle.\u003cbr\u003e\n(Bottle-Flash2 is a fork of [Bottle-Flash](https://pypi.python.org/pypi/bottle-flash/))\n\n# Installation\n\n\nYou can install `bottle-flash2` using [pip](https://pypi.org/project/bottle_flash2/).\n\n\n\tpip install bottle-flash2\n\n\n# Motivation\n\nI want to run \"Bottle-Flash\" in my environment.\u003cbr\u003e\n\n\tPython 3.5.1\n\tBottle v0.12.9\n\nit seems this project that it has not been maintained.\u003cbr\u003e\nSo I forked it.\n\n# Example\n\nPlease see [simple example](./example/README.md) directory.\n\nAn example of bottle-flash2 with [SimpleTemplate Engine](https://bottlepy.org/docs/dev/stpl.html) can be found [here](https://github.com/shinshin86/bottle-flash-2-example-with-simple-template-engine).\n\nAnd\n\n#### app.py\n\n~~~~python\nfrom bottle import Bottle, post, jinja2_template as template\nfrom bottle_flash2 import FlashPlugin\n\n# Flash Setup\napp = Bottle()\nCOOKIE_SECRET = 'super_secret_string'\napp.install(FlashPlugin(secret=[COOKIE_SECRET]))\n\n@post('/flash_sample_done')\ndef flash_sample():\n    app.flash(\"flash message is here\")\n    \n    # flash mesage is stored in list\n    # Therefore, it is possible to store a multiple messages.\n    app.flash(\"flash message 1\")\n    app.flash(\"flash message 2\")\n        \n    return template('index.html', app = app)\n\n~~~~\n\n#### index.html\n\n~~~~html\n {% set messages = app.get_flashed_messages() %}\n {% if messages %}\n \u003cdiv id=\"flash_messages\"\u003e\n \u003cul\u003e\n {% for m in messages %}\n \u003cli\u003e{{ m[0] }}\u003c/li\u003e\n {% endfor %}\n \u003c/ul\u003e\n \u003c/div\u003e\n {% endif %}\n~~~~\n\n# Bottle version (Test environment)\n\n\tversion 0.12.9 or above later.\n\t\n\tLatest Version -\u003e '0.13-dev'\n\n# Licence\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinshin86%2Fbottle-flash2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshinshin86%2Fbottle-flash2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinshin86%2Fbottle-flash2/lists"}