Re: [template] please help me in template tool kit module

veeru reddy <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.template-toolkit
Message-ID <CA+JyuYWoiGmb+6ym3Gii7opBbE0M4FuLCRyM54cP5iOUZ-bykA@mail.gmail.com>
I tried like this but its not printing what i want

[% FOREACH st IN university %]
[% st.name %]
[%st.location%]
studentdata:
[% FOREACH student IN st.branch.electronics.student %]

Component type: [%+ student.name +%][%+ student.number +%]

        [% FOREACH add IN studentaddress %]

        [% FOREACH address IN add.adress %]

       [% IF adress.name==student.name && adress.number ==student.number %]

            [% st.branch.electronics.student.size %]

 [% IF st.branch.electronics.student.size==1 %]
       [% adress.address %] .
 [%ELSIF st.branch.electronics.student.size==2 %]
       [% adress.address %] ,[% adress.address %] .
 [%ELSIF st.branch.electronics.student.size==2 %]
       [% adress.address %] ,[% adress.address %]or[% adress.address %] .

 [% END %]
 [% END %]
 [% END %]
 [% END %]
 [% END %]
 [% END %]

but its not working it printing address like this

when only one student name is there then it giving exactly like this
 address1.(i didn't write full addresss)

if we have two student address it printing like this
       address1, address1.
       address2,address2.
if we have three student address it printing like this
address1, address1 or address1.
       address2, address2 or address2.
  address3, address3 or address3.

i cant understand what is the problem with this what i did mistake? can
anyone help me how to print as i want please.

_______________________________________________
templates mailing list
[email protected]
http://mail.template-toolkit.org/mailman/listinfo/templates
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.