Thanks Reinout for the response,
i read the doc , just in time compilation to Python bytecode is used in
jinja..
is django default template also do this ?
which i see the reason why jinja faster.
mulianto
On Sun, Aug 14, 2011 at 6:19 AM, Reinout van Rees wrote:
> On 13-08-11 14:41, Phang Muli
>The application runs when I remote into the server and run
> the web pages with localhost on the 8000 port.
> How do I connect to this web page for demonstration purposes when I am
> not remoting into the virtual server.
>
> I tried just replacing localhost with the IP address with port 8000
> an
I think that if you performed the logic to determine if there actually
is something in the interest for that row in the view and
then only pass those components from the view, and not in the template
then your problem goes away.
On Aug 13, 8:53 pm, CrabbyPete wrote:
> I'm using the django templ
I have placed my django application on the virtual server from go
daddy. The application runs when I remote into the server and run
the web pages with localhost on the 8000 port.
How do I connect to this web page for demonstration purposes when I am
not remoting into the virtual server.
I tried
I'm using the django template system for format a text email. I send
it a dictionary and it formats the output. The problem is that it
inserts lots of newlines
Here is the template, and reports is a dictionary that contains an
event and a dictionary of interests
Weekly Contact List For {{date}}
{
*can you paste the entire error stacktrace? use http://dpaste.de/ or
equivalent to share it.
*
On Sat, Aug 13, 2011 at 8:01 PM, electrocoder wrote:
> my syntax is *{% autoescape off %} {{ myobje.mypage|slice:":150" }} {%
> endautoescape %}*
> *
> *
>
> --
> You received this message because you
my syntax is *{% autoescape off %} {{ myobje.mypage|slice:":150" }} {%
endautoescape %}*
*
*
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/django-users/-/UpRrFOATAeIJ
are you sure you used proper syntax?
{{ sliceable|slice:":2" }}
https://docs.djangoproject.com/en/dev/ref/templates/builtins/?from=olddocs#slice
On Sat, Aug 13, 2011 at 7:28 PM, electrocoder wrote:
> Blog on my local PC with "Could not parse the remainder: | Slice" I get the
> error message. H
Blog on my local PC with "Could not parse the remainder: | Slice" I get the
error message. How can I fix.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/django-users/-/A
On 13-08-11 14:41, Phang Mulianto wrote:
and i read about jinja template, why it can be faster than django
template engine ?
Jinja basically uses django's syntax, but (if my memory is correct) it
allows you to do more things than django's templates allows you to.
Is it faster? I thought ther
Nevermind. I get it. 'tags' has another field, description, which is what
the extra u'' is for.
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/django-users/-/jnvlX18nW
What happened here? Do I not understand .add()? I would have expected to
see
[(u'rcf_clients',)] not [(u'rcf_clients', u'')]
>>> print d.tags.values_list()
[]
>>> d.tags.add('rcf_clients')
>>> d.save()
>>> print d.tags.values_list()
[(u'rcf_clients', u'')]
>>>
--
You received this message bec
I have multiple models. I'm trying to create an admin site for all
models (using admin.site) and an admin site for each model (by
inheriting from AdminSite).
The admin.site is working as expected. The AdminSite will load the
app as normal but when I click on the model, I get a 404 error.
I'm fo
I'd like to see you model structure, but based on what I think it is:
class Entry(model.Model):
categories=models.ManyToManyField(Category)
class Content(models.Model):
entry=models.ForeignKey(Entry)
You have a Content Instance
You want to see other entries belonging to one or more of th
Hi Landy,
I'm seeing separate database tables created. The tables that are
created are _. I've tested in the latest
Django, python 2.7 and on windows with a sqlite3 database.
Thank you for your help You have given me a lot of great ideas.
Brian
--
You received this message because you
On 08/13/2011 05:00 PM, Karen Tracey wrote:
Plus, afaik, fields can not access form instances so this code would have
to live in the form subclass -- not practical in my use case.
Where I have done this (reluctantly) has been in the form (or perhaps it was
the field) clean method, where self is
*UPDATE:*
*
*
I was able to resolve the problem by looking up the contenttype manually so,
ct = orm['contenttypes.ContentType'].*objects.*get(app_label="blog",
model="Post")
Thanks Tom & Andrew (at south user listserv) for helping with this.
On Sat, Aug 13, 2011 at 1:14 PM, Chintan Tank wrote:
Tom,
I tried looking up the content_type and then using it, but it still throws
errors.
*1. I tried*
ct = ContentType.objects.get_for_model(Post)
chapter = orm.Chapter(rank=1, content_type=ct, object_id=blog.id)
*It gave error,*
ValueError: Cannot assign "": "Chapter.content_type" must
be a "Co
I'm trying to retrieve a m2m relation from a blog entry. It should give a
list of entries with the same categories. Below works when I work in the
shell.
from content.models import Entry
qs = Entry.objects.all()
obj = qs[0]
related = Entry.objects.filter(categories=obj.categories.all())
The ob
On Sat, Aug 13, 2011 at 8:18 AM, Petey wrote:
> I have a login/logout application - it works within its defined view
> (login/views.py) and templates (templates/login/index.html).
>
> I want to port this app so it will be displayed in base.html. The main
> problem is that I don't really know how
On Sat, Aug 13, 2011 at 4:41 AM, Jonas H. wrote:
> On 08/13/2011 06:33 AM, Karen Tracey wrote:
>
>> On Thu, Aug 11, 2011 at 7:03 AM, Jonas H. wrote:
>>
>> On 08/09/2011 12:45 AM, Jonas H. wrote:
>>>
>>> Hello list!
Is there any way to use a different value for a field when re-display
Thanks a lot derek! It's just all I was looking for :)
On Fri, Aug 12, 2011 at 4:03 PM, Derek wrote:
> On Aug 12, 1:29 pm, Isaac wrote:
> > Hi dudes,
> >
> > I'm having trouble at finding a solution for my problem. All I want to
> > do is tune django admin to show, for a given user an a given m
Hi all,
i need sugestion about templating.
if i use many include in django template, is it a good practice and effect
the load performance of the application ?
and i read about jinja template, why it can be faster than django template
engine ?
how many of you prefer jinja, and why ?
thanks all
I have a login/logout application - it works within its defined view
(login/views.py) and templates (templates/login/index.html).
I want to port this app so it will be displayed in base.html. The main
problem is that I don't really know how to import this app correctly to
base.html.
If I use c
On 08/13/2011 06:33 AM, Karen Tracey wrote:
On Thu, Aug 11, 2011 at 7:03 AM, Jonas H. wrote:
On 08/09/2011 12:45 AM, Jonas H. wrote:
Hello list!
Is there any way to use a different value for a field when re-displaying
a form? I.e. if a user enters '42' into an IntegerField but made the
othe
25 matches
Mail list logo