Is there a reason for the middleware being old-style classes? If
middleware was defined as Middleware(object) we could extend it like
this without modifying Django's source:
class MyCacheMiddleware(CacheMiddleware):
def process_request(self, request):
if check_request(request):
Hi Adrian,
> In your case, pass ITEM_NAMES[item.type]
> to the template context.
Easier said than done. The template was intended to do something like
this:
{% for item in items %}
{{ ITEM_NAMES[item.type] }}
{% endfor %}
Is it possible to achieve this without passing an additional item_ty
On 10/13/05, Andreas Stuhlmüller <[EMAIL PROTECTED]> wrote:
> Is there a reason for the middleware being old-style classes?
Speaking for my own code: No, there is no reason, I am just not in
the habit of writing new-style classes. And I don't think there is
a reason for the other middlewares bein
On 9/29/05, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote:
> To pick one example: in a dynamic serving situation, KeepAlive is
> your friend; [ snip a lot ]
Hmmm... HTTP Keep-Alive? Then either I'm misunderstanding
you, or everything you say is exactly opposite to what I remember
reading elsewhere
Andreas Stuhlmüller wrote:
> Hi Adrian,
>
>
>>In your case, pass ITEM_NAMES[item.type]
>>to the template context.
>
>
> Easier said than done. The template was intended to do something like
> this:
>
> {% for item in items %}
> {{ ITEM_NAMES[item.type] }}
> {% endfor %}
>
> Is it possibl
On Oct 13, 2005, at 7:15 AM, Sune Kirkeby wrote:
On 9/29/05, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote:
To pick one example: in a dynamic serving situation, KeepAlive is
your friend; [ snip a lot ]
Hmmm... HTTP Keep-Alive? Then either I'm misunderstanding
you, or everything you say is ex
Hello!
I am writing my first app for django, areticles. All tutorials read. I
want from app:
- add articles by users for readding by admin and publish them or del
- archive by months
- insert last 5 bref_articles to index page of site
Create a model
from django.core import meta
cla
On 10/13/05, Andreas Stuhlmüller <[EMAIL PROTECTED]> wrote:
> Is there a reason for the middleware being old-style classes? If
> middleware was defined as Middleware(object) we could extend it like
> this without modifying Django's source:
Nope, no reason. Generally throughout the Django code, we
Hi,
I have a simple problem I can't seem to sort out, I can't make use of
the media root under the built in server when developing.
I have done this in main.py in my project:
MEDIA_ROOT = '/path/to/some/folder/www/'
MEDIA_URL = 'http://localhost:8000/www/'
I expected everything under the MEDIA
Is there a way to create a manipulator that will span a foreign key
relationship, similar to the "edit_inline" feature in the Admin tool?
I know I cannot leverage the edit_inline feature now (ticket #535 may
fix that) but is there a "smart" way of leveraging the validation and
form processing fea
Ian Maurer wrote:
> Is there a way to create a manipulator that will span a foreign key
> relationship, similar to the "edit_inline" feature in the Admin tool?
>
> I know I cannot leverage the edit_inline feature now (ticket #535 may
> fix that) but is there a "smart" way of leveraging the valida
That's a pretty slick implementation, I'd like to try it out... some questions:
Is it in a usable format?
Are there any directions for pulling this branch down to my local environment?
What happens if the main branch gets updated?
thanks...
ian
On 10/13/05, Robert Wittams <[EMAIL PROTECTED]>
Ian Maurer wrote:
> That's a pretty slick implementation, I'd like to try it out... some
> questions:
>
> Is it in a usable format?
> Are there any directions for pulling this branch down to my local environment?
> What happens if the main branch gets updated?
>
>
> thanks...
> ian
>
>
>
W
Easy enough. I will let you know if I run into any problems...
thanks again,
ian
On 10/13/05, Robert Wittams <[EMAIL PROTECTED]> wrote:
>
> Ian Maurer wrote:
> > That's a pretty slick implementation, I'd like to try it out... some
> > questions:
> >
> > Is it in a usable format?
> > Are there a
Maniac wrote:
> You could subclass django.core.extensions.DjangoContext and
> prefill it with your everpresent variables in __init__().
I ended up subclassing "Context". I was wrong when I said writing a
custom Context doesn't seem to save code -- passing MyContext(request)
to render_to_response
15 matches
Mail list logo