Re: Add custom page attributes?

15 views
Skip to first unread message

Jonas Obrist

unread,
Sep 25, 2012, 7:19:28 AM9/25/12
to djang...@googlegroups.com
Hi Stuart,

This is not directly possible and currently the most viable workaround is to create a second model holding your custom data with a OneToOne/ForeignKey to Page. Then unregister the PageAdmin and re-register it with an inline attached that hooks your model onto the PageAdmin.

Jonas

On Tuesday, September 25, 2012 12:08:38 PM UTC+2, Stuart Axon wrote:
Hello all,
  I want to add template variable that is global to a page, is there a way to do this?

The variable would set a banner image for my template (or default to the default one).

Cheers,
Stuart

Stuart Axon

unread,
Sep 25, 2012, 12:06:40 PM9/25/12
to djang...@googlegroups.com
Cheers.   In the end we got a ContextProcessor working to do what we needed.
Reply all
Reply to author
Forward
0 new messages