Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Thu Mar 28, 2024 4:18 pm
VoIP Billing solution


All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Class.FormHandler.inc.php cid create BUG
PostPosted: Wed Dec 10, 2008 3:38 am 
Offline

Joined: Wed Dec 10, 2008 3:29 am
Posts: 2
hi,all

if set cid '0123-0125' ,Class.FormHandler.inc.php is create
"0123","124","125"
change Class.FormHandler.inc.php
1338 if (is_numeric($arr_value_explode[0]) && is_numeric($arr_value_explode[1]) && $arr_value_explode[0] < $arr_value_explode[1] ){
1339 for ($kk=$arr_value_explode[0];$kk<=$arr_value_explode[1];$kk++){
1340 $arr_value_to_import[] = $kk;
1341 }

to
if (is_numeric($arr_value_explode[0]) && is_numeric($arr_value_explode[1]) && $arr_value_explode[0] < $arr_value_explode[1] ){
$perfix_len=strlen($arr_value_explode[0])-strlen(ltrim($arr_value_explode[0],'0'));
$perfix=substr($arr_value_explode[0],0,$perfix_len);
for ($kk=$arr_value_explode[0]+0;$kk<=$arr_value_explode[1];$kk++){
$arr_value_to_import[] = $perfix.$kk;
}

it's ok


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 10, 2008 6:16 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
Thanks for the fix.

http://www.asterisk2billing.org/cgi-bin ... geset/1340


Top
 Profile  
 
 Post subject:
PostPosted: Thu Dec 11, 2008 6:51 am 
Offline

Joined: Wed Dec 10, 2008 3:29 am
Posts: 2
hi,
1340 it's bug
why? I'm writter "$kk=$arr_value_explode[0]+0"
Because if $arr_value_explode[0] = "0123"
$kk=$arr_value_explode[0]; then
$arr_value_to_import[] = $perfix.$kk; =="00123" it's error
if $kk=$arr_value_explode[0]+0;
then
$arr_value_to_import[] = $perfix.$kk; =="0123" it's OK


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 
Hosted Voice Broadcast


All times are UTC


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group