Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
0 votes
1.5k views
in Q2A Core by

We usually use the following codes in other scripts to change Arabic numerals into Hindi numerals

PHP:

function number($num){
$num=str_replace("1","١",$num);
$num=str_replace("2","٢",$num);
$num=str_replace("3","٣",$num);
$num=str_replace("4","٤",$num);
$num=str_replace("5","٥",$num);
$num=str_replace("6","٦",$num);
$num=str_replace("7","٧",$num);
$num=str_replace("8","٨",$num);
$num=str_replace("9","٩",$num);
$num=str_replace("0","٠",$num);
return $num;
}

number('1999');

Java script:
var datee= writeIslamicDate();
var datee=datee.replace("1","١");
var datee=datee.replace("2","٢");
var datee=datee.replace("3","٣");
var datee=datee.replace("4","٤");
var datee=datee.replace("5","٥");
var datee=datee.replace("6","٦");
var datee=datee.replace("7","٧");
var datee=datee.replace("8","٨");
var datee=datee.replace("9","٩");
var datee=datee.replace("0","٠");

$('#datee span').html("" + datee + "");

So, please help us to change all Arabic numerals into Hindi numerals in Q2A!

 

Please log in or register to answer this question.

...