Returns an HTML table constructed from the dict of form errors.

[TR(k, v) for k, v in form.errors.items()]

Iterates through the dict and creates a table row TR for each dict item.
The TR assumes that each item would be a TD, so that doesn't need to be 
explicit.
The square brackets [] indicate a "list comprehension",  which creates a 
list of the TR elements.
The asterisk unpacks the list into the TABLE.

Hope that helps a little.  Regards,  David



On Tuesday, September 4, 2012 10:37:25 AM UTC+1, Hassan Alnatour wrote:
>
> Dear ALL , 
>
> I need help to understand this return  , can anyone explain  it to me 
> please ?
>
> return TABLE(*[TR(k, v) for k, v in form.errors.items()])
>
>

-- 



Reply via email to