正在调试中!!"; ?> "; $remote_ip .= $tmp; $tmp = "lcl_ip_$i"; $tmp = dechex(${$tmp}); $tmp = omc_keep_length($tmp,'0','2'); if($DEBUG) echo "lcl_ip_$i = $tmp
"; $local_ip .= $tmp; } if($DEBUG) { echo "SMPP:
"; echo "link_type=$link_type
"; echo "connect_type=$connect_type
"; echo "session_type=$session_type
"; echo "system_id=$system_id
"; echo "password=$password
"; echo "local_gtt=$local_gtt
"; echo "remote_gtt=$remote_gtt
"; echo "local_ip=$local_ip
"; echo "remote_ip=$remote_ip
"; echo "session_timer=$session_timer
"; echo "enquire_timer=$enquire_timer
"; echo "inact_timer=$inact_timer
"; echo "response_timer=$response_timer
"; echo "opposite_num=$opposite_num
"; } $link_type = omc_keep_length($link_type,'0','2'); $connect_type = omc_keep_length($connect_type,'0','2'); $session_type = omc_keep_length($session_type,'0','2'); $system_id = omc_keep_length(toHex($system_id),'0','32','0'); $password = omc_keep_length(toHex($password),'0','18','0'); $local_gtt = omc_keep_length(toHex($local_gtt),'0','32','0'); $remote_gtt= omc_keep_length(toHex($remote_gtt),'0','32','0'); $local_ip = omc_keep_length($local_ip,'F','8','0'); $remote_ip = omc_keep_length($remote_ip,'F','8','0'); $session_timer= omc_keep_length(dechex($session_timer),'0','8'); $enquire_timer= omc_keep_length(dechex($enquire_timer),'0','8'); $inact_timer = omc_keep_length(dechex($inact_timer),'0','8'); $response_timer = omc_keep_length(dechex($response_timer),'0','8'); $opposite_num = omc_keep_length(toHex($opposite_num),'0','16','0'); $initValue_0 = $smpp_init; $initValue_0 = setBitValue($initValue_0,$smpp_array[0][1],$link_type); $initValue_0 = setBitValue($initValue_0,$smpp_array[1][1],$connect_type); $initValue_0 = setBitValue($initValue_0,$smpp_array[2][1],$session_type); $initValue_0 = setBitValue($initValue_0,$smpp_array[3][1],$system_id); $initValue_0 = setBitValue($initValue_0,$smpp_array[4][1],$password); $initValue_0 = setBitValue($initValue_0,$smpp_array[5][1],$local_gtt); $initValue_0 = setBitValue($initValue_0,$smpp_array[6][1],$remote_gtt); $initValue_0 = setBitValue($initValue_0,$smpp_array[7][1],$local_ip); $initValue_0 = setBitValue($initValue_0,$smpp_array[8][1],$remote_ip); $initValue_0 = setBitValue($initValue_0,$smpp_array[9][1],$session_timer); $initValue_0 = setBitValue($initValue_0,$smpp_array[10][1],$enquire_timer); $initValue_0 = setBitValue($initValue_0,$smpp_array[11][1],$inact_timer); $initValue_0 = setBitValue($initValue_0,$smpp_array[12][1],$response_timer); $initValue_0 = setBitValue($initValue_0,$smpp_array[13][1],$opposite_num); $initValue_0 = setBitValue($initValue_0,$smpp_array[14][1],'01'); if($DEBUG) echo "initValue_0 = $initValue_0
"; $levelArr=explode('.',$smpp_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "update $smpp_sqltable set initValue = '$initValue_0' where level_1 = '$level_1' and level_2 = '$level_2' and level_3 = '$level_3' and instanceNo = '$instanceNo'"; mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "$setsql
"; if($DEBUG) { echo "SMSC:
"; echo "smsc_session_type=$session_type
"; echo "smsc_opposite_num=$opposite_num
"; echo "smsc_dcs=$smsc_dcs
"; } $smsc_dcs= omc_keep_length($smsc_dcs,'0','2'); $initValue_1 = $smsc_init; $initValue_1 = setBitValue($initValue_1,$smsc_array[0][1],'01'); $initValue_1 = setBitValue($initValue_1,$smsc_array[1][1],$session_type); $initValue_1 = setBitValue($initValue_1,$smsc_array[2][1],$opposite_num); $initValue_1 = setBitValue($initValue_1,$smsc_array[3][1],'01'); $initValue_1 = setBitValue($initValue_1,$smsc_array[4][1],$smsc_dcs); if($DEBUG) echo "initValue_1 = $initValue_1
"; $levelArr=explode('.',$smsc_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "update $smsc_sqltable set initValue = '$initValue_1' where level_1 = '$level_1' and level_2 = '$level_2' and level_3 = '$level_3' and instanceNo = '$smsc_ins'"; mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "$setsql
"; if(!$DEBUG) { echo ""; } } if($DEBUG) echo "instanceNo=$instanceNo
"; if($DEBUG) echo "back_page=$back_page
"; if($instanceNo == 'New') { $levelArr=explode('.',$smpp_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "select initValue from $smpp_sqltable WHERE level_1='$level_1' AND level_2='$level_2' AND level_3='$level_3' "; $result = mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; $smpp_ins = 0; while($smpp_row = mysqli_fetch_array($result)) { $enable_flag = getBitValue($smpp_row[0],$smpp_array[14][1]); if ($DEBUG) echo "smpp_flag = $enable_flag
"; if($enable_flag == 0) break; $smpp_ins++; } if($DEBUG) echo "smpp_ins = $smpp_ins
"; $levelArr=explode('.',$smsc_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "select initValue from $smsc_sqltable WHERE level_1='$level_1' AND level_2='$level_2' AND level_3='$level_3' "; $result = mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; $smsc_ins = 0; while($smsc_row = mysqli_fetch_array($result)) { $enable_flag = getBitValue($smsc_row[0],$smsc_array[0][1]); if ($DEBUG)echo "smsc_flag = $enable_flag
"; if($enable_flag == 0) break; $smsc_ins++; } if($DEBUG) echo "smsc_ins = $smsc_ins
"; //clear old value $initValue = omc_keep_length($initValue,'0','24'); $setsql = "update $smsc_sqltable set initValue = '$initValue' where level_1 = '2' and level_2 = '2' and level_3 = '0' and instanceNo = '$smsc_ins' "; mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; $initValue = omc_keep_length($initValue,'0','212'); $setsql = "update $smpp_sqltable set initValue = '$initValue' where level_1 = '2' and level_2 = '1' and level_3 = '0' and instanceNo = '$smpp_ins' "; mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; if($DEBUG) echo "dcs=$smsc_dcs
"; } else { $smpp_ins = $instanceNo; } //========================================================== //取数据库数据 //========================================================== $levelArr=explode('.',$smpp_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "select initValue from $smpp_sqltable WHERE level_1='$level_1' AND level_2='$level_2' AND level_3='$level_3' AND instanceNo='$smpp_ins'"; $result = mysqli_query($pubConn,$setsql); $smpp_row = mysqli_fetch_array($result); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; $link_type = getBitValue($smpp_row[0],$smpp_array[0][1]); $connect_type = getBitValue($smpp_row[0],$smpp_array[1][1]); $session_type = getBitValue($smpp_row[0],$smpp_array[2][1]); $system_id = toAscii(getBitValue($smpp_row[0],$smpp_array[3][1])); $password = toAscii(getBitValue($smpp_row[0],$smpp_array[4][1])); $local_gtt = toAscii(getBitValue($smpp_row[0],$smpp_array[5][1])); $remote_gtt = toAscii(getBitValue($smpp_row[0],$smpp_array[6][1])); $local_ip = getBitValue($smpp_row[0],$smpp_array[7][1]); $remote_ip = getBitValue($smpp_row[0],$smpp_array[8][1]); $session_timer = hexdec(getBitValue($smpp_row[0],$smpp_array[9][1])); $enquire_timer = hexdec(getBitValue($smpp_row[0],$smpp_array[10][1])); $inact_timer = hexdec(getBitValue($smpp_row[0],$smpp_array[11][1])); $response_timer = hexdec(getBitValue($smpp_row[0],$smpp_array[12][1])); $opposite_num = toAscii(getBitValue($smpp_row[0],$smpp_array[13][1])); if($instanceNo != 'New') { $levelArr=explode('.',$smsc_oid); for($j=0;$jlevelArr[$j]={$levelArr[$j]}"; } $setsql = "select initValue from $smsc_sqltable WHERE level_1='$level_1' AND level_2='$level_2' AND level_3='$level_3' "; $result = mysqli_query($pubConn,$setsql); echo mysqli_error($pubConn); if($DEBUG) echo "
$setsql
"; $smsc_ins = 0; while($smsc_row = mysqli_fetch_array($result)) { $smsc_session_type = getBitValue($smsc_row[0],$smsc_array[1][1]); $smsc_opposite_num = toAscii(getBitValue($smsc_row[0],$smsc_array[2][1])); if($smsc_session_type == $session_type && $smsc_opposite_num == $opposite_num) { $smsc_dcs = getBitValue($smsc_row[0],$smsc_array[4][1]); break; } $smsc_ins++; } } //========================================================== //输出并显示数据 //========================================================== echo "
"; if ($DEBUG)echo "---$smpp_ins---$smsc_ins---
"; echo ""; echo ""; echo ""; echo ""; echo ""; ?> "; echo ""; echo ""; echo "Configuration > Network > Element > SMSC"; echo ""; showHelp($helpId); echo ""; echo ""; echo ""; echo "
"; echo ""; echo ""; echo ""; echo "
"; echo "SMPP link:  "; echo ""; echo ""; echo "$strBack"; echo "
"; ?> "; echo ""; echo ""; echo ""; //========================================================== //输出Link type //========================================================== if($DEBUG) echo "chang_link_type = $change_link_type"; if (isset($change_link_type)) $link_type = $change_link_type; if($DEBUG) echo "link_type = $link_type
"; echo "" ; echo ""; echo ""; //========================================================== //输出Connection type //========================================================== echo "" ; echo ""; echo ""; //========================================================== //输出Session type //========================================================== echo "" ; echo ""; echo ""; //========================================================== //输出System ID //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出Password //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出GT //========================================================== if($link_type == 0) { echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; echo ""; } //========================================================== //输出IP //========================================================== else { $rmt_ip[0] = hexdec(getBitValue($remote_ip,'0.0-0.7')); $rmt_ip[1] = hexdec(getBitValue($remote_ip,'1.0-1.7')); $rmt_ip[2] = hexdec(getBitValue($remote_ip,'2.0-2.7')); $rmt_ip[3] = hexdec(getBitValue($remote_ip,'3.0-3.7')); $lcl_ip[0] = hexdec(getBitValue($local_ip,'0.0-0.7')); $lcl_ip[1] = hexdec(getBitValue($local_ip,'1.0-1.7')); $lcl_ip[2] = hexdec(getBitValue($local_ip,'2.0-2.7')); $lcl_ip[3] = hexdec(getBitValue($local_ip,'3.0-3.7')); echo ""; echo ""; echo ""; echo ""; } //========================================================== //输出Opposite service number //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出DCS //========================================================== echo "
"; echo "" ; echo ""; echo ""; //========================================================== //输出Session timer //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出Enquire link timer //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出Inactivity timer //========================================================== echo ""; echo ""; echo ""; echo ""; //========================================================== //输出Response timer //========================================================== echo ""; echo ""; echo ""; echo ""; echo "
ParametersValue
Link type
Connection type
Session type
System ID
Password
Opposite GT
Local GT
Opposite IP"; for($i=0; $i<4; $i++) { echo ""; if($i != 3) echo "."; } echo "
Local IP"; for($i=0; $i<4; $i++) { echo ""; if($i != 3) echo "."; } echo "
Opposite service number
Data coding scheme
Session timer
Enquire link timer
Inactivity timer
Response timer
"; echo "
"; ?>