django - python underscore function name -


i reading django article on form validatin here , came across this

validationerror(_('invalid value'), code='invalid') 

my question _('invalid value') does?

it's translation purpose

you should see @ begining of script

from django.utils.translation import ugettext _ 

you can see complete explanation in doc


Comments

Popular posts from this blog

c++ - Linked List error when inserting for the last time -

java - activate/deactivate sonar maven plugin by profile? -

tsql - Pivot with Temp Table (definition for column must include data type) -- SQL Server 2008 -