Django ifequal problem comparing 2 datatypes -


post.dys string variable , day.day integer.

both have same value, there no output expected.

i think it's variable-type problem, i'm not sure.

how can solved?

{% ifequal post.days|slugify day.day|slugify %}    test {% endifequal %} 

yes, 2 variables should same type work properly. see manual page python , django. may cast variable same type using str() function in view, example.


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

java - Output of Eclipse is rubbish -

jquery - Confused with JSON data and normal data in Django ajax request -