The effects of alcohol on sustanon 250 leucine for – real weight loss & bodybuilding benefits?
Search
Close
AI Search
Classic Search
 Search Phrase:
 Search Type:
Advanced search options
 Search in Forums:
 Search in date period:

 Sort Search Results by:

AI Assistant
add custom number t...
 
Notifications
Clear all

[Solved] add custom number type to replace english number

3 Posts
2 Users
1 Reactions
5,214 Views
(@janakkafle)
Posts: 2
New Member
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 
[#3674]

i want to replace English number with Devanagari number and add some code in function.php of theme and it works on theme but doesn't work on plugin can you please guide me how can i replace English number . 

the code i have use

function make_nep_number( $str ) {
$engNumber = array(1,2,3,4,5,6,7,8,9,0);
$nepNumber = array("१","२","३","४","५","६","७","८","९","०");
$converted = str_replace($engNumber, $nepNumber, $str);

return $converted;
}

add_filter( 'comments_number', 'make_nep_number' );


 
Posted : 06/02/2022 8:24 am
Asti
 Asti
(@asti)
Posts: 8260
Illustrious Member Support
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

@janakkafle,

You should use the get_comments_number hook instead of the comments_number one. 


In case you want to say thank you! 🙂
We'd really appreciate if you leave a good review on the plugin page.
This is the best way to say thank you to this project and the support team.

 
Posted : 07/02/2022 12:51 pm
janakkafle reacted
(@janakkafle)
Posts: 2
New Member
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
 

Thanks It works . 


 
Posted : 08/02/2022 1:16 pm