On May 25, 4:43 am, stevedegrace wrote:
> And you are absolutely correct, using a local variable in the render
> method and not rebinding self,ip resolves the problem. Thank you very
> much. Can you explain why this is?
"Once a node is parsed, its render method may be called
And you are absolutely correct, using a local variable in the render
method and not rebinding self,ip resolves the problem. Thank you very
much. Can you explain why this is?
On May 23, 5:34 am, bruno desthuilliers
wrote:
> On May 23, 5:37 am, stevedegrace
Thanks for the advice. I'm actually using this tag on a private
moderation page to quickly satisfy my curiosity about which countries
generate the most spam in my comments (FYI: Russia is winning hands
down so far).
On May 23, 10:24 am, Brice Leroy wrote:
> Be careful will
Be careful will computing location on rendering. IPs will change in time. The
pattern is not clear but expect the information to expire.
As you only extract the country, it shouldn't be an issue, but if you drill
down to Zip code I would commend you to store it with the comment's author
(less
On May 23, 5:37 am, stevedegrace wrote:
> I developed a custom tag to look up the country of a certain IP
> address using an IP to country database. It's sort of rough and ready,
> but it should work. The idea is that you read the comment.ip_address,
> feed it to the {% country
5 matches
Mail list logo