flavourfiles - Serves static files related to flav…¶

Summary¶

This plugin allows flavour templates to use file urls that will resolve to files in the flavour directory. Those files will then get served by Pyblosxom.

This solves the problem that flavour packs are currently difficult to package, install, and maintain because static files (images, css, js, …) have to get put somewhere else and served by the web server and this is difficult to walk a user through.

It handles urls that start with flavourfiles/, then the flavour name, then the path to the file.

For example:

http://example.com/blog/flavourfiles/html/style.css

Note

This plugin is very beta! It’s missing important functionality, probably has bugs, and hasn’t been well tested!

Install¶

This plugin comes with Pyblosxom. To install, do the following:

  1. Add Pyblosxom.plugins.flavourfiles to the load_plugins list of your config.py file.

  2. In templates you want to use flavourfiles, use urls like this:

    $(base_url)/flavourfiles/$(flavour)/path-to-file
    

    For example:

    <img src="$(base_url)/flavourfiles/$(flavour)/header_image.jpg">
    

The $(base_url) will get filled in with the correct url root.

The $(flavour) will get filled in with the name of the url. This allows users to change the flavour name without having to update all the templates.

License¶

Plugin is distributed under license: MIT License

PyBlosxom

Navigation

  • Introduction
  • About Pyblosxom
  • License
  • What’s new in 1.5
  • What’s new in older versions
  • Installing Pyblosxom
  • Upgrading Pyblosxom
  • Pyblosxom on the command line
  • Deploying Pyblosxom with CGI
  • Deploying Pyblosxom with Paste
  • Deploying Pyblosxom with Apache and mod_wsgi
  • Deploying Pyblosxom with Lighttpd and fastcgi
  • Deploy Pyblosxom with Static Rendering
  • Configuring Pyblosxom
  • Writing Entries
  • Flavours and Templates
  • Syndication
  • Renderers
  • Comments
  • Plugins
  • Authors
  • Glossary
  • acronyms - Marks acronyms and abbreviations in…
  • akismetcomments - Rejects comments using akismet…
  • check_blacklist - Rejects comments using a word black…
  • check_javascript - Rejects comments using JavaScript…
  • check_nonhuman - Rejects non-human comments….
  • comments - Adds comments to a blog entry….
  • conditionalhttp - Allows browser-side caching with if…
  • disqus - Lets me use Disqus for comments….
  • entrytitle - Puts entry title in page title….
  • firstdaydiv - Adds a token which tells us whether…
  • flavourfiles - Serves static files related to flav…
  • magicword - Magic word method for reducing comm…
  • markdown_parser - Markdown entry parser…
  • no_old_comments - Prevent comments on entries older t…
  • pages - Allows you to include non-blog-entr…
  • paginate - Allows navigation by page for index…
  • pyarchives - Builds month/year-based archives li…
  • pycalendar - Displays a calendar on your blog….
  • pycategories - Builds a list of categories….
  • pyfilenamemtime - Allows you to codify the mtime in t…
  • readmore - Breaks blog entries into summary an…
  • rst_parser - restructured text support for blog …
  • tags - Tags plugin…
  • trackback - Trackback support….
  • w3cdate - Adds a ‘w3cdate’ variable which is …
  • xmlrpc_pingback - XMLRPC pingback support….
  • yeararchives - Builds year-based archives listing….
  • Contributing
  • Hacking on PyBlosxom
  • Pyblosxom Architecture
  • Writing Plugins
  • Code Documentation
  • Testing
  • Release process

Related Topics

  • Documentation overview
    • Previous: firstdaydiv - Adds a token which tells us whether…
    • Next: magicword - Magic word method for reducing comm…

Quick search

©Creative Commons CC0 - http://creativecommons.org/publicdomain/zero/1.0/. | Powered by Sphinx 1.7.6 & Alabaster 0.7.8 | Page source