python - How to convert normal numbers into arabic numbers in django -



python - How to convert normal numbers into arabic numbers in django -

i have list of numbers [1,2,3,....]

now want convert them standard arabic numbers using django.

is possible? ideas welcome.

try function:

def entoarnumb(number): dic = { 0:'۰', 1:'١', 2:'٢', 3:'۳', 4:'۴', 5:'۵', 6:'۶', 7:'۷', 8:'۸', 9:'۹', .:'۰', } homecoming dic.get(number)

and utilize this:

ar_numbers = [entoarnumb(num) num in numbers]

python django

Comments

Popular posts from this blog

formatting - SAS SQL Datepart function returning odd values -

c++ - Apple Mach-O Linker Error(Duplicate Symbols For Architecture armv7) -

php - Yii 2: Unable to find a class into the extension 'yii2-admin' -