Re: Single-line comment doesn't seem to work

2007-08-08 Thread [EMAIL PROTECTED]

Thanks for all the replies!

I am using 0.95, maybe that's why it doesn't work.

~cw

On Aug 8, 12:42 am, Collin Grady <[EMAIL PROTECTED]> wrote:
> What version of django are you using? I seem to remember the single
> line comments being added after 0.96, though I could be mistaken.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Single-line comment doesn't seem to work

2007-08-08 Thread Collin Grady

What version of django are you using? I seem to remember the single
line comments being added after 0.96, though I could be mistaken.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Single-line comment doesn't seem to work

2007-08-07 Thread Nicola Larosa

[EMAIL PROTECTED] wrote:
> The templates are html...so to comment you would use 

HTML comments are included in the output that goes to the user, so careful
with what you write in there. :-)

Django comments, OTOH, do not exit the system.


-- 
Nicola Larosa - http://www.tekNico.net/

These three disciplines - writing, engineering, and artistry - are not
so different from one another. [...] When you're able to think easily
in all three modes one by one, you will soon find yourself thinking in
all three simultaneously. The writer, engineer and artist overlap and
merge, Voltron-style, to form The Designer. -- Craig Cook, January 2007



--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Single-line comment doesn't seem to work

2007-08-07 Thread SmileyChris

On Aug 8, 4:12 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
wrote:
> The templates are html...so to comment you would use 

The templates are rendered by Django, so {##} should work. I just
tested it and it's working fine for me...

>>> from django.template import Template, Context
>>> content = ''' Test single line and multi-lines comments

Test1
hello {# This should be commented out #} hello
{{ link|escape }}

{% comment %}
The following two lines should be commented out
Test2
{{ link|urlencode }}
{% endcomment %}

Test3
{{ html|escape }} '''
>>> print Template(content).render(Context())
 Test single line and multi-lines comments

Test1
hello  hello




Test3


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Re: Single-line comment doesn't seem to work

2007-08-07 Thread [EMAIL PROTECTED]

The templates are html...so to comment you would use 

On Aug 7, 2:32 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote:
> I've the following template and when I render it, the single line
> comment doesn't get commented out.
> Am I missing something; I'm new to Django and just start playing with
> the templates.
>
>  template
> Test single line and multi-lines comments
>
> Test1
> hello {# This should be commented out #} hello
> {{ link|escape }}
>
> {% comment %}
> The following two lines should be commented out
> Test2
> {{ link|urlencode }}
> {% endcomment %}
>
> Test3
> {{ html|escape }}
>
> ### Render output>>> print render_to_response('testtmpl.html', {'link':link, 
> 'html':html})
>
> Content-Type: text/html; charset=utf-8
>
> Test single line and multi-lines comments
>
> Test1
> hello {# This should be commented out #} hello  
> <<<---http://172.27.78.97:/is/launch_calendar/event/?type__id__exact=3
>
> Test3
> this is a quote statment  some other \stuff
>
> Thanks,
> ~Carmen


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---



Single-line comment doesn't seem to work

2007-08-07 Thread [EMAIL PROTECTED]

I've the following template and when I render it, the single line
comment doesn't get commented out.
Am I missing something; I'm new to Django and just start playing with
the templates.

 template
Test single line and multi-lines comments

Test1
hello {# This should be commented out #} hello
{{ link|escape }}

{% comment %}
The following two lines should be commented out
Test2
{{ link|urlencode }}
{% endcomment %}

Test3
{{ html|escape }}


### Render output
>>> print render_to_response('testtmpl.html', {'link':link, 'html':html})
Content-Type: text/html; charset=utf-8

Test single line and multi-lines comments

Test1
hello {# This should be commented out #} hello  <<<---
http://172.27.78.97:/is/launch_calendar/event/?type__id__exact=3



Test3
this is a quote statment  some other \stuff

Thanks,
~Carmen


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~--~~~~--~~--~--~---