Zahhar Posted January 27, 2005 Report Share Posted January 27, 2005 Hello, guys! I have a problem I can't solve myself. I am web-developer from Estonia and I need to implement an algorithm for converting a random numeric to correct latvian words. You know, this is needed for printed accounts for example. Can you give me proper php-function or class to convert i.e. "53.10" to "Piecdesmit trīs lati 10 santīmi"? I have found this script on your site, but seems it is not correct. If I convert "23123.23" I get "desmit tukstosi simti desmit lati desmit santimi", wich definilty not right. I would be very thankful if you help me! P.S. PHP::PEAR repository has class named Number2Words with english, russian, estonian, lithuanian and others language support. It would be good if your community add there Latvian language support as well! Link to comment Share on other sites More sharing options...
Venom Posted January 28, 2005 Report Share Posted January 28, 2005 here you go http://paste.php.lv/1587 it returns santimes in an accounting matter - 2 numbers followed by santīmi/s, though works ok to 1000nds of billions Link to comment Share on other sites More sharing options...
Zahhar Posted February 2, 2005 Author Report Share Posted February 2, 2005 Thank you very much, you helped me a lot! Link to comment Share on other sites More sharing options...
Klez Posted August 8, 2005 Report Share Posted August 8, 2005 ja padodam 90, tad atgriezh '90 lats' Link to comment Share on other sites More sharing options...
Venom Posted August 8, 2005 Report Share Posted August 8, 2005 angliski, angliski (: laikam kautkur bija izlabota versija Link to comment Share on other sites More sharing options...
Venom Posted August 8, 2005 Report Share Posted August 8, 2005 šis laikam http://paste.php.lv/2304 Link to comment Share on other sites More sharing options...
superKrona Posted September 4, 2007 Report Share Posted September 4, 2007 Pielaboju rakstību skaitļiem x0 un x1: http://paste.php.lv/6009 Link to comment Share on other sites More sharing options...
Toms Posted September 4, 2007 Report Share Posted September 4, 2007 astoņpadsmimt => astoņpadsmit Link to comment Share on other sites More sharing options...
Val Posted September 4, 2007 Report Share Posted September 4, 2007 trīsdesmit arī Link to comment Share on other sites More sharing options...
superKrona Posted September 5, 2007 Report Share Posted September 5, 2007 (edited) Gramatika, gramatika. Es domāju lats, lati Tagad arī paši skaitļi rakstās pareizi: simts->simti; tūkstotis->tūkstoši utt. arī santīms->santīmi http://paste.php.lv/6019 Edited September 5, 2007 by superKrona Link to comment Share on other sites More sharing options...
Andrew Posted December 4, 2007 Report Share Posted December 4, 2007 Sveiki! Sastapos ar nelielu problēmu skirptā. Mēģinam uzrakstīt vārdiem nenoapaļotu summu 4.999: četri lati un 100 santīmi :) Link to comment Share on other sites More sharing options...
superKrona Posted December 4, 2007 Report Share Posted December 4, 2007 Nu noapaļo, pirms nolasi http://paste.php.lv/6521 Link to comment Share on other sites More sharing options...
brachux Posted February 24, 2009 Report Share Posted February 24, 2009 Nu noapaļo, pirms nolasihttp://paste.php.lv/6521 kāds nevarētu palabot šo kodu, lai darbotos pie summām zem 1Ls un arī ar 0Ls.. būtu ļoti pateicīgs ;) Link to comment Share on other sites More sharing options...
superKrona Posted February 17, 2010 Report Share Posted February 17, 2010 Lai darbojies pie summām zem 1Ls un arī ar 0Ls! http://paste.php.lv/b99a473bd15ae69e27cc94ad18d515f4?lang=php Link to comment Share on other sites More sharing options...
2easy Posted February 17, 2010 Report Share Posted February 17, 2010 neesmu testējis, bet izskatās, ka šo varētu likt pie noderīgām funkcijām http://php.lv/f/topic/15423-noderigas-funkcijas/ Link to comment Share on other sites More sharing options...
Recommended Posts