{ "info": { "author": "Arnold Krille for bcs kommunikationsloesungen", "author_email": "a.krille@b-c-s.de", "bugtrack_url": null, "classifiers": [], "description": "mezzanine-pageimages\n====================\n\nDefine (background-/banner-)images per page\n\n# The Problem\n\nAt least our designer likes to create websites where pages can have individual backgrounds. Or individual banners. So for example the index-page has a generic background, while all pages under _Contact_ should have another background.\n\nMezzanine has this great feature that templates are searched by\n`page-name.html`, `.html` and then `page.html`. so one\nwould just create specific templates for the pages that get different\nbackground. Its a nice solution that even works. But it has drawbacks:\n - To change the background, the designer has to ask the programmer because it\n can't be changed in the admin-backend.\n - When you have multiple child-pages which should all get the background of\n the parent-page, you end up with templates for each page.\n - When the designer or writer adds another page, the programmer has to add\n another template.\n\nMostly the problem is mixing content with design-code.\n\n# The Solution\n\nHere is how mezzanine-pageimages solves this:\n - In the admin-backend we just add a way to define images for certain roles\n and specific to certain pages. Plus a way to define default-images for the\n roles.\n - We define a template-tag `pageimage` that takes a role and the looks for\n the fitting image for the current page.\n - When there is no image for that role for the current page, it looks for an\n image on the parent page. It goes upwards until there is no parent or an\n image is found.\n - When there is still no image found, the default image for that role is\n returned, if there is one defined.\n\n# Install\n\nThis package is on pypi.python.org. To simply install it just do `pip install mezzanine-pageimage`. Or define it as a requirement in your _requirements.txt_ or _setup.py_.\n\nFor hacking on mezzanine-pageimages do a git-checkout and install via `pip install -e`. Or install by `pip install -e git+https://github.com/bcs-de/mezzanine-pageimages.git#egg=mezzanine-pageimages`.\n\n# Usage\n\nAdd the app to your `INSTALLED_APPS`. You can define your own image-roles in the `SETTINGS` in settings.py:\n\n```python\nPAGEIMAGE_TYPES = (\n ('BACKGROUND', 'Description text'),\n)\n```\n\nThen use it in your templates:\n\n```\n{% load pageimage_tags %}\n\nLets get the url for the background image: {% pageimage 'BACKGROUND' %}\n```", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/bcs-de/mezzanine-pageimages", "keywords": null, "license": "Licensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.", "maintainer": null, "maintainer_email": null, "name": "mezzanine-pageimages", "package_url": "https://pypi.org/project/mezzanine-pageimages/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/mezzanine-pageimages/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://github.com/bcs-de/mezzanine-pageimages" }, "release_url": "https://pypi.org/project/mezzanine-pageimages/0.2.3/", "requires_dist": null, "requires_python": null, "summary": "Define (background-/banner-)images per page in mezzanine.", "version": "0.2.3" }, "last_serial": 1007518, "releases": { "0.2.0": [ { "comment_text": "", "digests": { "md5": "e1f729e0f74be603ef68db7cdac5a9c1", "sha256": "0582baf8270cbeb7f3cb5bf2f14c6aa1c482635ea7ac2d46ea4ec2fb52b08450" }, "downloads": -1, "filename": "mezzanine-pageimages-0.2.0.tar.gz", "has_sig": false, "md5_digest": "e1f729e0f74be603ef68db7cdac5a9c1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8535, "upload_time": "2013-10-25T13:27:15", "url": "https://files.pythonhosted.org/packages/61/bd/d7875928b009b508da61cf8f5a2e0de6f5915b035d3e3c676d2d044ad984/mezzanine-pageimages-0.2.0.tar.gz" } ], "0.2.1": [ { "comment_text": "", "digests": { "md5": "c5b6feba31014a8dbb7f756d57e63235", "sha256": "f58a345f502d03f9de52323c3aeecfda77f6d86f4509ae3d6ebd88b5a2ec3f5e" }, "downloads": -1, "filename": "mezzanine-pageimages-0.2.1.tar.gz", "has_sig": false, "md5_digest": "c5b6feba31014a8dbb7f756d57e63235", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9037, "upload_time": "2013-10-25T14:54:39", "url": "https://files.pythonhosted.org/packages/37/e9/67b86a88bce78f12fdd8e40214d7dc3d66cea95a1ca2dff0cf2997841aaf/mezzanine-pageimages-0.2.1.tar.gz" } ], "0.2.2": [ { "comment_text": "", "digests": { "md5": "be92d98eb23410edaca56992c9f8d8fc", "sha256": "9f1dd937d093890eafbc0fd87b399de6837f56a805f63a1fed3bc6752a062fab" }, "downloads": -1, "filename": "mezzanine-pageimages-0.2.2.tar.gz", "has_sig": false, "md5_digest": "be92d98eb23410edaca56992c9f8d8fc", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9527, "upload_time": "2013-10-25T14:59:29", "url": "https://files.pythonhosted.org/packages/de/89/43cdfc1d32330fd9f05b016b910bbcb883476e06765ac1e9f512615c53bb/mezzanine-pageimages-0.2.2.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "7e7f51d94801633ee2fd70730713341e", "sha256": "cce000c02a8eaede37150599b4320052850669ce3e98eac104d60851aaf2c400" }, "downloads": -1, "filename": "mezzanine-pageimages-0.2.3.tar.gz", "has_sig": false, "md5_digest": "7e7f51d94801633ee2fd70730713341e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9305, "upload_time": "2014-02-21T13:55:21", "url": "https://files.pythonhosted.org/packages/9b/e5/56a2c5a404a115a94aba7327db0d0deb3283a524811e0008801ebbc78d29/mezzanine-pageimages-0.2.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "7e7f51d94801633ee2fd70730713341e", "sha256": "cce000c02a8eaede37150599b4320052850669ce3e98eac104d60851aaf2c400" }, "downloads": -1, "filename": "mezzanine-pageimages-0.2.3.tar.gz", "has_sig": false, "md5_digest": "7e7f51d94801633ee2fd70730713341e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 9305, "upload_time": "2014-02-21T13:55:21", "url": "https://files.pythonhosted.org/packages/9b/e5/56a2c5a404a115a94aba7327db0d0deb3283a524811e0008801ebbc78d29/mezzanine-pageimages-0.2.3.tar.gz" } ] }