Someone might have a quicker/better way, but what about:


   $numbers = '1223123';
   $numberarray = str_split($numbers,1);


Richard Dunne wrote:
Can anyone tell me how how to convert a string of integers into an array of single digit 
integers.  i.e. "1223123" into ['1','2,','2','3','1,'2','3'] ?  When I retreive 
a column of single digit integers I end up with a long string of numbers.  I think PHP is 
seeing this as one whole number and therefore is not splitting or exploding it. I hope I 
am wrong in my thinking and there is a simple solution, though I am not seeing it.  Can 
anyone help me?


PHP Database Mailing List (
To unsubscribe, visit:

Reply via email to