Re: How to understand below html code?

2018-03-27 Thread Utpal Brahma
Thanks a lot ---
Lachlan Musicman
Daniel Hepper

and
Daniel Hepper

Your answer meant a lot to me.Thank you very much guys.

On Tue, Mar 27, 2018 at 1:15 PM, Daniel Hepper 
wrote:

> Hi,
>
> I just want to chime in and clarify that while Django does indeed support
> Jinja2, it is not the default template language.
>
> Django comes with its own template language, which is used in the
> tutorial, the documentation and probably most articles related to Django.
>
> The documentation gives a good overview: https://docs.djangoproject.
> com/en/2.0/topics/templates/#the-django-template-language
>
> However, Lachian's interpretation of the template is correct.
>
> It is worth noting that Jinja2 is actually modeled after the Django
> template language, so it is easy to confuse the two on a first glance.
>
> Cheers,
> Daniel
>
> On Tue, Mar 27, 2018 at 6:17 AM, Lachlan Musicman 
> wrote:
>
>> Utpal, it's not pure HTML. It's got some templating in there as well -
>> Jinja2 I think is the default.
>>
>> Regardless, it reads like Python:
>>
>> if the list exists, open an unnumbered list
>> for every question in the list, create a dot point with the list
>> question. The list question will be a html a link back to the question. End
>> for
>> end list
>> else
>> "no list"
>> end if
>>
>>
>> Cheers
>> L.
>>
>>
>>
>>
>> --
>> "The antidote to apocalypticism is *apocalyptic civics*. Apocalyptic
>> civics is the insistence that we cannot ignore the truth, nor should we
>> panic about it. It is a shared consciousness that our institutions have
>> failed and our ecosystem is collapsing, yet we are still here — and we are
>> creative agents who can shape our destinies. Apocalyptic civics is the
>> conviction that the only way out is through, and the only way through is
>> together. "
>>
>> *Greg Bloom* @greggish https://twitter.com/greggish/s
>> tatus/873177525903609857
>>
>> On 27 March 2018 at 15:11, Utpal Brahma 
>> wrote:
>>
>>> I am in tutorial 3 of Django.But i am stuck in understanding the below
>>> code.Please heLP me!!!
>>>
>>>
>>> {% if latest_question_list %}
>>> 
>>> {% for question in latest_question_list %}
>>> {{
>>> question.question_text }}
>>> {% endfor %}
>>> 
>>> {% else %}
>>> No polls are available.
>>> {% endif %}
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to django-users+unsubscr...@googlegroups.com.
>>> To post to this group, send email to django-users@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/django-users.
>>> To view this discussion on the web visit https://groups.google.com/d/ms
>>> gid/django-users/160290fc-a15a-43f4-b1f1-7cdcb6d5c9b1%40googlegroups.com
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/django-users/CAGBeqiNY05tUr%2B2xsFqcsqxfAW0N0Jvw4aBDVi8-
>> OJL_LYoDCA%40mail.gmail.com
>> 
>> .
>>
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/django-users/shmTr4Vegoc/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/CAHEnUVXUB1jdrOJLN5FhxdDfduTh4
> 4Mw_xKYE9AOOHfVERkkvA%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To 

Re: How to understand below html code?

2018-03-27 Thread Daniel Hepper
Hi,

I just want to chime in and clarify that while Django does indeed support
Jinja2, it is not the default template language.

Django comes with its own template language, which is used in the tutorial,
the documentation and probably most articles related to Django.

The documentation gives a good overview:
https://docs.djangoproject.com/en/2.0/topics/templates/#the-django-template-language

However, Lachian's interpretation of the template is correct.

It is worth noting that Jinja2 is actually modeled after the Django
template language, so it is easy to confuse the two on a first glance.

Cheers,
Daniel

On Tue, Mar 27, 2018 at 6:17 AM, Lachlan Musicman  wrote:

> Utpal, it's not pure HTML. It's got some templating in there as well -
> Jinja2 I think is the default.
>
> Regardless, it reads like Python:
>
> if the list exists, open an unnumbered list
> for every question in the list, create a dot point with the list question.
> The list question will be a html a link back to the question. End for
> end list
> else
> "no list"
> end if
>
>
> Cheers
> L.
>
>
>
>
> --
> "The antidote to apocalypticism is *apocalyptic civics*. Apocalyptic
> civics is the insistence that we cannot ignore the truth, nor should we
> panic about it. It is a shared consciousness that our institutions have
> failed and our ecosystem is collapsing, yet we are still here — and we are
> creative agents who can shape our destinies. Apocalyptic civics is the
> conviction that the only way out is through, and the only way through is
> together. "
>
> *Greg Bloom* @greggish https://twitter.com/greggish/
> status/873177525903609857
>
> On 27 March 2018 at 15:11, Utpal Brahma  wrote:
>
>> I am in tutorial 3 of Django.But i am stuck in understanding the below
>> code.Please heLP me!!!
>>
>>
>> {% if latest_question_list %}
>> 
>> {% for question in latest_question_list %}
>> {{
>> question.question_text }}
>> {% endfor %}
>> 
>> {% else %}
>> No polls are available.
>> {% endif %}
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit https://groups.google.com/d/ms
>> gid/django-users/160290fc-a15a-43f4-b1f1-7cdcb6d5c9b1%40googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/CAGBeqiNY05tUr%2B2xsFqcsqxfAW0N0Jvw4aBDVi8-
> OJL_LYoDCA%40mail.gmail.com
> 
> .
>
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAHEnUVXUB1jdrOJLN5FhxdDfduTh44Mw_xKYE9AOOHfVERkkvA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to understand below html code?

2018-03-27 Thread Jani Tiainen
Hi.

That's actually Django template which uses Django templating language. It's
not Jinja2 as suggested in other post.

What it does is well explained in that other post though.

ti 27. maaliskuuta 2018 klo 7.12 Utpal Brahma 
kirjoitti:

> I am in tutorial 3 of Django.But i am stuck in understanding the below
> code.Please heLP me!!!
>
>
> {% if latest_question_list %}
> 
> {% for question in latest_question_list %}
> {{ question.question_text
> }}
> {% endfor %}
> 
> {% else %}
> No polls are available.
> {% endif %}
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/160290fc-a15a-43f4-b1f1-7cdcb6d5c9b1%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAHn91ocEvE9cWhm%3D8CgVxwD9ZUsPMEij27r70DNubnhB1vpQAg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to understand below html code?

2018-03-26 Thread Lachlan Musicman
Utpal, it's not pure HTML. It's got some templating in there as well -
Jinja2 I think is the default.

Regardless, it reads like Python:

if the list exists, open an unnumbered list
for every question in the list, create a dot point with the list question.
The list question will be a html a link back to the question. End for
end list
else
"no list"
end if


Cheers
L.




--
"The antidote to apocalypticism is *apocalyptic civics*. Apocalyptic civics
is the insistence that we cannot ignore the truth, nor should we panic
about it. It is a shared consciousness that our institutions have failed
and our ecosystem is collapsing, yet we are still here — and we are
creative agents who can shape our destinies. Apocalyptic civics is the
conviction that the only way out is through, and the only way through is
together. "

*Greg Bloom* @greggish
https://twitter.com/greggish/status/873177525903609857

On 27 March 2018 at 15:11, Utpal Brahma  wrote:

> I am in tutorial 3 of Django.But i am stuck in understanding the below
> code.Please heLP me!!!
>
>
> {% if latest_question_list %}
> 
> {% for question in latest_question_list %}
> {{ question.question_text
> }}
> {% endfor %}
> 
> {% else %}
> No polls are available.
> {% endif %}
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/django-users/160290fc-a15a-43f4-b1f1-7cdcb6d5c9b1%40googlegroups.com
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAGBeqiNY05tUr%2B2xsFqcsqxfAW0N0Jvw4aBDVi8-OJL_LYoDCA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


How to understand below html code?

2018-03-26 Thread Utpal Brahma
I am in tutorial 3 of Django.But i am stuck in understanding the below 
code.Please heLP me!!!


{% if latest_question_list %}

{% for question in latest_question_list %}
{{ question.question_text 
}}
{% endfor %}

{% else %}
No polls are available.
{% endif %}

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/160290fc-a15a-43f4-b1f1-7cdcb6d5c9b1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.