bsmbahamas
01-21-2008, 11:23 AM
i have an 8 digit string...
$id = 12345678
what i want to do is split it in two so that
i have 4 digits in each part.
$arr = str_split($id,4);
seems to be a solution, but i think
my host is using php 4 and that functions
appears to only work in php 5.
any other way? or maybe i'm using it wrong.
i copied and pasted sample code from php.net and
another site, but none worked. so i'm assuming it
because my host is using php 4.
how do i tell the php versiona gain?
php_info() or something liek that right?
$id = 12345678
what i want to do is split it in two so that
i have 4 digits in each part.
$arr = str_split($id,4);
seems to be a solution, but i think
my host is using php 4 and that functions
appears to only work in php 5.
any other way? or maybe i'm using it wrong.
i copied and pasted sample code from php.net and
another site, but none worked. so i'm assuming it
because my host is using php 4.
how do i tell the php versiona gain?
php_info() or something liek that right?