lundi 20 avril 2015

Comma separated string split by length but keeping the comma separation?

I have a string like this "105321,102305,321506,0321561,3215658" and i need to split this string by the comma (,) and with a specific length, so if the length of each string part is 15, the splited array must be like:

105321,102305
321506,0321561
3215658 

I try several ways but i can't find the right approach to do this

Aucun commentaire:

Enregistrer un commentaire