Login

Tag "texteditor"

Snippet List

EditingMiddleware (quickly open views and templates in your text editor!)

Heavily based on [Snippet 1033](http://www.djangosnippets.org/snippets/1033/) and [Snippet 766](http://www.djangosnippets.org/snippets/766/). This snippet tracks what view and templates are used to render HTML responses and inserts a small dialog in the top right corner of the output with links to all the files. If your text editor support opening files from a browser protocol you can click the links to open the files right up! For example TextMate supports the `txmt://` protocol. Really saves some time if you find yourself editing a lot of templates. ![txt](http://img.skitch.com/20090602-11df2tfg273p99i95nfx6a74qe.png) **Usage** 1. Save this snippet in a file called `middleware.py` on your Python Path. 2. Add `middleware.EditingMiddleware` to your `MIDDLEWARE_CLASSES`. 3. Browse to any HTML page on your site!

  • middleware
  • editing
  • texteditor
  • editor
Read More

1 snippet posted so far.