PHP Classes

PHP Split Number: Split a long number into an array of smaller parts

Recommend this page to a friend!
  Info   View files Example   View files View files (2)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2014-11-12 (5 years ago) RSS 2.0 feedNot enough user ratingsTotal: 160 All time: 8,701 This week: 385Up
Version License PHP version Categories
number-splitter-up 0.1GNU General Publi...5.0Algorithms, PHP 5, Text processing, Math
Description Author

This class can split a long number into an array of smaller parts.

It takes a number of many digits and splits it into parts so that each part does not exceed a given maximum number size.

The number parts are returned in an array or as a string.

Innovation Award
PHP Programming Innovation award nominee
November 2014
Number 9

Prize: One subscription to the PDF edition of the PHP Architect magazine
Some applications need to show numbers composed by a long series of digits. Often the numbers are split in groups of a smaller number of digits that are easier to ready and copy.

For some applications it is convenient that each group of digits does not show a number above a given limit.

This class can split long numbers into groups of digits on which each group does not exceed a given limit number, so each group may have one more digit or not depending on whether the given limit was already reached or not.

Manuel Lemos
  Performance   Level  
Name: Anthony Rogers <contact>
Classes: 3 packages by
Country: United Kingdom
Age: 35
All time rank: 58830 in United Kingdom
Week rank: 747 Down26 in United Kingdom Up
Innovation award
Innovation award
Nominee: 1x


  Files folder image Files  
File Role Description
Accessible without login Plain text file index.php Example Test and Example Page
Plain text file number-splitter-upper.php Class Main Class

 Version Control Unique User Downloads Download Rankings  
This week:0
All time:8,701
This week:385Up

For more information send a message to info at phpclasses dot org.