2016-04-26 03:30:23 +02:00
< ? php
/* $Id$ */
/*
2018-06-11 05:31:45 +02:00
click_to_call . php
2021-01-27 19:49:01 +01:00
Copyright ( C ) 2008 , 2021 Mark J Crane
2016-04-26 03:30:23 +02:00
All rights reserved .
Redistribution and use in source and binary forms , with or without
modification , are permitted provided that the following conditions are met :
1. Redistributions of source code must retain the above copyright notice ,
this list of conditions and the following disclaimer .
2. Redistributions in binary form must reproduce the above copyright
notice , this list of conditions and the following disclaimer in the
documentation and / or other materials provided with the distribution .
THIS SOFTWARE IS PROVIDED `` AS IS '' AND ANY EXPRESS OR IMPLIED WARRANTIES ,
INCLUDING , BUT NOT LIMITED TO , THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED . IN NO EVENT SHALL THE
AUTHOR BE LIABLE FOR ANY DIRECT , INDIRECT , INCIDENTAL , SPECIAL , EXEMPLARY ,
OR CONSEQUENTIAL DAMAGES ( INCLUDING , BUT NOT LIMITED TO , PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES ; LOSS OF USE , DATA , OR PROFITS ; OR BUSINESS
INTERRUPTION ) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY , WHETHER IN
CONTRACT , STRICT LIABILITY , OR TORT ( INCLUDING NEGLIGENCE OR OTHERWISE )
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE , EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE .
Contributor ( s ) :
Mark J Crane < markjcrane @ fusionpbx . com >
James Rose < james . o . rose @ gmail . com >
*/
2018-06-11 05:31:45 +02:00
2022-10-11 00:35:14 +02:00
//includes files
2023-06-15 19:28:23 +02:00
require_once dirname ( __DIR__ , 2 ) . " /resources/require.php " ;
2018-06-01 05:19:05 +02:00
require_once " resources/check_auth.php " ;
//check permissions
if ( permission_exists ( 'click_to_call_view' )) {
//access granted
}
else {
echo " access denied " ;
exit ;
}
2016-04-26 03:30:23 +02:00
//add multi-lingual support
$language = new text ;
$text = $language -> get ();
//include the header
require_once " resources/header.php " ;
2018-06-11 05:31:45 +02:00
//send the call
2018-12-05 08:45:40 +01:00
if ( is_array ( $_GET ) && isset ( $_GET [ 'src' ]) && isset ( $_GET [ 'dest' ])) {
2018-06-11 05:31:45 +02:00
//retrieve submitted variables
2018-12-05 08:45:40 +01:00
$src = check_str ( $_GET [ 'src' ]);
$src_cid_name = check_str ( $_GET [ 'src_cid_name' ]);
$src_cid_number = check_str ( $_GET [ 'src_cid_number' ]);
2018-06-11 05:31:45 +02:00
2018-12-05 08:45:40 +01:00
$dest = check_str ( $_GET [ 'dest' ]);
$dest_cid_name = check_str ( $_GET [ 'dest_cid_name' ]);
$dest_cid_number = check_str ( $_GET [ 'dest_cid_number' ]);
2018-06-11 05:31:45 +02:00
2018-12-05 08:45:40 +01:00
$auto_answer = check_str ( $_GET [ 'auto_answer' ]); //true,false
$rec = check_str ( $_GET [ 'rec' ]); //true,false
$ringback = check_str ( $_GET [ 'ringback' ]);
2020-10-22 10:28:51 +02:00
$context = $_SESSION [ 'domain_name' ];
2018-06-11 05:31:45 +02:00
//clean up variable values
2022-08-01 16:45:21 +02:00
$src = str_replace ( array ( '(' , ')' , ' ' ), '' , $src );
2018-06-11 05:31:45 +02:00
$dest = ( strpbrk ( $dest , '@' ) != FALSE ) ? str_replace ( array ( '(' , ')' , ' ' ), '' , $dest ) : str_replace ( array ( '.' , '(' , ')' , '-' , ' ' ), '' , $dest ); //don't strip periods or dashes in sip-uri calls, only phone numbers
//adjust variable values
$sip_auto_answer = ( $auto_answer == " true " ) ? " ,sip_auto_answer=true " : null ;
//mozilla thunderbird TBDialout workaround (seems it can only handle the first %NUM%)
$dest = ( $dest == " %NUM% " ) ? $src_cid_number : $dest ;
//translate ringback
switch ( $ringback ) {
case " music " : $ringback_value = " \ 'local_stream://moh \ ' " ; break ;
case " uk-ring " : $ringback_value = " \ '%(400,200,400,450);%(400,2200,400,450) \ ' " ; break ;
case " fr-ring " : $ringback_value = " \ '%(1500,3500,440.0,0.0) \ ' " ; break ;
case " pt-ring " : $ringback_value = " \ '%(1000,5000,400.0,0.0) \ ' " ; break ;
case " rs-ring " : $ringback_value = " \ '%(1000,4000,425.0,0.0) \ ' " ; break ;
case " it-ring " : $ringback_value = " \ '%(1000,4000,425.0,0.0) \ ' " ; break ;
case " de-ring " : $ringback_value = " \ '%(1000,4000,425.0,0.0) \ ' " ; break ;
case " us-ring " :
default :
$ringback = 'us-ring' ;
$ringback_value = " \ '%(2000,4000,440.0,480.0) \ ' " ;
2016-04-26 03:30:23 +02:00
}
2018-06-11 05:31:45 +02:00
//create the even socket connection and send the event socket command
2023-12-03 01:16:18 +01:00
$esl = event_socket :: create ();
if ( $esl -> is_connected ()) {
2018-06-11 05:31:45 +02:00
2023-12-03 01:16:18 +01:00
//set call uuid
$origination_uuid = trim ( event_socket :: api ( " create_uuid " ));
2018-06-11 05:31:45 +02:00
2023-12-03 01:16:18 +01:00
//add record path and name
if ( $rec == " true " ) {
$record_path = $_SESSION [ 'switch' ][ 'recordings' ][ 'dir' ] . " / " . $_SESSION [ 'domain_name' ] . " /archive/ " . date ( " Y " ) . " / " . date ( " M " ) . " / " . date ( " d " );
if ( isset ( $_SESSION [ 'recordings' ][ 'extension' ][ 'text' ])) {
$record_extension = $_SESSION [ 'recordings' ][ 'extension' ][ 'text' ];
}
else {
$record_extension = 'wav' ;
}
if ( isset ( $_SESSION [ 'recordings' ][ 'template' ][ 'text' ])) {
//${year}${month}${day}-${caller_id_number}-${caller_destination}-${uuid}.${record_extension}
$record_name = $_SESSION [ 'recordings' ][ 'template' ][ 'text' ];
$record_name = str_replace ( '${year}' , date ( " Y " ), $record_name );
$record_name = str_replace ( '${month}' , date ( " M " ), $record_name );
$record_name = str_replace ( '${day}' , date ( " d " ), $record_name );
$record_name = str_replace ( '${source}' , $src , $record_name );
$record_name = str_replace ( '${caller_id_name}' , $src_cid_name , $record_name );
$record_name = str_replace ( '${caller_id_number}' , $src_cid_number , $record_name );
$record_name = str_replace ( '${caller_destination}' , $dest , $record_name );
$record_name = str_replace ( '${destination}' , $dest , $record_name );
$record_name = str_replace ( '${uuid}' , $origination_uuid , $record_name );
$record_name = str_replace ( '${record_extension}' , $record_extension , $record_name );
}
else {
$record_name = $origination_uuid . '.' . $record_extension ;
}
2018-06-11 05:31:45 +02:00
}
2023-12-03 01:16:18 +01:00
//determine call direction
$dir = ( user_exists ( $dest )) ? 'local' : 'outbound' ;
2018-06-11 05:31:45 +02:00
2023-12-03 01:16:18 +01:00
//define a leg - set source to display the defined caller id name and number
$source_common = " { " ;
$source_common .= " click_to_call=true " ;
$source_common .= " ,origination_caller_id_name=' " . $src_cid_name . " ' " ;
$source_common .= " ,origination_caller_id_number= " . $src_cid_number ;
$source_common .= " ,instant_ringback=true " ;
$source_common .= " ,ringback= " . $ringback_value ;
$source_common .= " ,presence_id= " . $src . " @ " . $_SESSION [ 'domains' ][ $domain_uuid ][ 'domain_name' ];
$source_common .= " ,call_direction= " . $dir ;
if ( $rec == " true " ) {
$source_common .= " ,record_path=' " . $record_path . " ' " ;
$source_common .= " ,record_name=' " . $record_name . " ' " ;
2016-04-26 03:30:23 +02:00
}
2023-12-03 01:16:18 +01:00
if ( user_exists ( $src )) {
//source is a local extension
$source = $source_common . $sip_auto_answer .
" ,domain_uuid= " . $domain_uuid .
" ,domain_name= " . $_SESSION [ 'domains' ][ $domain_uuid ][ 'domain_name' ] . " }user/ " . $src . " @ " . $_SESSION [ 'domains' ][ $domain_uuid ][ 'domain_name' ];
2016-04-26 03:30:23 +02:00
}
2023-12-03 01:16:18 +01:00
else {
//source is an external number
$bridge_array = outbound_route_to_bridge ( $_SESSION [ 'domain_uuid' ], $src );
$source = $source_common . " } " . $bridge_array [ 0 ];
2018-06-11 05:31:45 +02:00
}
2023-12-03 01:16:18 +01:00
unset ( $source_common );
//define b leg - set destination to display the defined caller id name and number
$destination_common = " &bridge( { origination_caller_id_name=' " . $dest_cid_name . " ',origination_caller_id_number= " . $dest_cid_number ;
if ( user_exists ( $dest )) {
//destination is a local extension
2018-06-11 05:31:45 +02:00
if ( strpbrk ( $dest , '@' ) != FALSE ) { //sip-uri
$switch_cmd = $destination_common . " ,call_direction=outbound}sofia/external/ " . $dest . " ) " ;
}
else { //not sip-uri
$switch_cmd = " &transfer(' " . $dest . " XML " . $context . " ') " ;
}
}
2023-12-03 01:16:18 +01:00
else {
//local extension (source) > external number (destination)
if ( user_exists ( $src ) && empty ( $dest_cid_number )) {
//retrieve outbound caller id from the (source) extension
$sql = " select outbound_caller_id_name, outbound_caller_id_number from v_extensions where domain_uuid = :domain_uuid and extension = :src " ;
$parameters [ 'domain_uuid' ] = $_SESSION [ 'domain_uuid' ];
$parameters [ 'src' ] = $src ;
$database = new database ;
$result = $database -> select ( $sql , $parameters , 'all' );
2024-08-22 20:41:10 +02:00
foreach ( $result as $row ) {
2023-12-03 01:16:18 +01:00
$dest_cid_name = $row [ " outbound_caller_id_name " ];
$dest_cid_number = $row [ " outbound_caller_id_number " ];
break ; //limit to 1 row
}
}
if ( permission_exists ( 'click_to_call_call' )) {
if ( strpbrk ( $dest , '@' ) != FALSE ) { //sip-uri
$switch_cmd = $destination_common . " ,call_direction=outbound}sofia/external/ " . $dest . " ) " ;
}
else { //not sip-uri
$bridge_array = outbound_route_to_bridge ( $_SESSION [ 'domain_uuid' ], $dest );
//$switch_cmd = $destination_common."}".$bridge_array[0].")"; // wouldn't set cdr destination correctly, so below used instead
$switch_cmd = " &transfer(' " . $dest . " XML " . $context . " ') " ;
}
}
}
unset ( $destination_common );
} else {
2018-06-11 05:31:45 +02:00
//error message
echo " <div align='center'><strong>Connection to Event Socket failed.</strong></div> " ;
}
2023-12-03 01:16:18 +01:00
//ensure we are still connected and send the event socket command
if ( $esl -> is_connected ()) {
2018-06-11 05:31:45 +02:00
//display the last command
2023-12-03 01:16:18 +01:00
$switch_cmd = " originate " . $source . $switch_cmd ;
2021-01-28 06:25:04 +01:00
echo " <div align='center'><strong> " . escape ( $src ) . " has called " . escape ( $dest ) . " </strong></div> \n " ;
2018-06-11 05:31:45 +02:00
//show the command result
2023-12-03 01:16:18 +01:00
$result = trim ( event_socket :: api ( $switch_cmd ));
2018-06-11 05:31:45 +02:00
if ( substr ( $result , 0 , 3 ) == " +OK " ) {
//$uuid = substr($result, 4);
if ( $rec == " true " ) {
//use the server's time zone to ensure it matches the time zone used by freeswitch
date_default_timezone_set ( $_SESSION [ 'time_zone' ][ 'system' ]);
//create the api record command and send it over event socket
2021-01-28 06:25:04 +01:00
if ( is_uuid ( $origination_uuid ) && file_exists ( $record_path )) {
2023-12-03 01:16:18 +01:00
$switch_cmd = " uuid_record $origination_uuid start $record_path / $record_name " ;
2021-01-28 06:25:04 +01:00
}
2023-12-03 01:16:18 +01:00
$result2 = trim ( event_socket :: api ( $switch_cmd ));
2018-06-11 05:31:45 +02:00
}
2016-04-26 03:30:23 +02:00
}
2021-01-28 06:25:04 +01:00
echo " <div align='center'><br /> " . escape ( $result ) . " <br /><br /></div> \n " ;
2023-12-03 01:16:18 +01:00
} else {
//error message
echo " <div align='center'><strong>Connection to Event Socket failed.</strong></div> " ;
2016-04-26 03:30:23 +02:00
}
2018-06-11 05:31:45 +02:00
}
2016-04-26 03:30:23 +02:00
//show html form
echo " <table width= \" 100% \" border= \" 0 \" cellpadding= \" 0 \" cellspacing= \" 0 \" > \n " ;
echo " <tr> \n " ;
echo " <td align='left'> \n " ;
echo " <span class= \" title \" > \n " ;
echo " <strong> " . $text [ 'label-click2call' ] . " </strong> \n " ;
echo " </span> \n " ;
echo " </td> \n " ;
echo " <td align='right'> \n " ;
echo " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td align='left' colspan='2'> \n " ;
echo " <span class= \" vexpl \" > \n " ;
echo " " . $text [ 'desc-click2call' ] . " \n " ;
echo " </span> \n " ;
echo " </td> \n " ;
echo " \n " ;
echo " </tr> \n " ;
echo " </table> " ;
echo " <br /> " ;
2018-12-05 08:45:40 +01:00
echo " <form method= \" get \" > \n " ;
2016-04-26 03:30:23 +02:00
echo " <table border='0' width='100%' cellpadding='0' cellspacing='0' \n " ;
echo " <tr> \n " ;
echo " <td class='vncellreq' width='40%'> " . $text [ 'label-src-caller-id-nam' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2018-08-27 22:50:31 +02:00
echo " <input name= \" src_cid_name \" value=' " . escape ( $src_cid_name ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-src-caller-id-nam' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncellreq'> " . $text [ 'label-src-caller-id-num' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2018-08-27 22:50:31 +02:00
echo " <input name= \" src_cid_number \" value=' " . escape ( $src_cid_number ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-src-caller-id-num' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncell' width='40%'> " . $text [ 'label-dest-caller-id-nam' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2018-08-27 22:50:31 +02:00
echo " <input name= \" dest_cid_name \" value=' " . escape ( $dest_cid_name ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-dest-caller-id-nam' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncell'> " . $text [ 'label-dest-caller-id-num' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2018-08-27 22:50:31 +02:00
echo " <input name= \" dest_cid_number \" value=' " . escape ( $dest_cid_number ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-dest-caller-id-num' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncellreq'> " . $text [ 'label-src-num' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2021-01-28 06:25:04 +01:00
echo " <input name= \" src \" value=' " . escape ( $src ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-src-num' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncellreq'> " . $text [ 'label-dest-num' ] . " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
2021-01-28 06:25:04 +01:00
echo " <input name= \" dest \" value=' " . escape ( $dest ) . " ' class='formfld'> \n " ;
2016-04-26 03:30:23 +02:00
echo " <br /> \n " ;
echo " " . $text [ 'desc-dest-num' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncell' valign='top' align='left' nowrap='nowrap'> \n " ;
echo " " . $text [ 'label-auto-answer' ] . " \n " ;
echo " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
echo " <select class='formfld' name='auto_answer'> \n " ;
echo " <option value=''></option> \n " ;
if ( $auto_answer == " true " ) {
echo " <option value='true' selected='selected'> " . $text [ 'label-true' ] . " </option> \n " ;
}
else {
echo " <option value='true'> " . $text [ 'label-true' ] . " </option> \n " ;
}
if ( $auto_answer == " false " ) {
echo " <option value='false' selected='selected'> " . $text [ 'label-false' ] . " </option> \n " ;
}
else {
echo " <option value='false'> " . $text [ 'label-false' ] . " </option> \n " ;
}
echo " </select> \n " ;
echo " <br /> \n " ;
echo $text [ 'desc-auto-answer' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncell' valign='top' align='left' nowrap> \n " ;
echo " " . $text [ 'label-record' ] . " \n " ;
echo " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
echo " <select class='formfld' name='rec'> \n " ;
echo " <option value=''></option> \n " ;
if ( $rec == " true " ) {
echo " <option value='true' selected='selected'> " . $text [ 'label-true' ] . " </option> \n " ;
}
else {
echo " <option value='true'> " . $text [ 'label-true' ] . " </option> \n " ;
}
if ( $rec == " false " ) {
echo " <option value='false' selected='selected'> " . $text [ 'label-false' ] . " </option> \n " ;
}
else {
echo " <option value='false'> " . $text [ 'label-false' ] . " </option> \n " ;
}
echo " </select> \n " ;
echo " <br /> \n " ;
echo $text [ 'desc-record' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td class='vncellreq' valign='top' align='left' nowrap> \n " ;
echo " " . $text [ 'label-ringback' ] . " \n " ;
echo " </td> \n " ;
echo " <td class='vtable' align='left'> \n " ;
echo " <select class='formfld' name='ringback'> \n " ;
echo " <option value=''></option> \n " ;
if ( $ringback == " us-ring " ) {
echo " <option value='us-ring' selected='selected'> " . $text [ 'opt-usring' ] . " </option> \n " ;
}
else {
echo " <option value='us-ring'> " . $text [ 'opt-usring' ] . " </option> \n " ;
}
if ( $ringback == " fr-ring " ) {
echo " <option value='fr-ring' selected='selected'> " . $text [ 'opt-frring' ] . " </option> \n " ;
}
else {
echo " <option value='fr-ring'> " . $text [ 'opt-frring' ] . " </option> \n " ;
}
if ( $ringback == " pt-ring " ) {
echo " <option value='pt-ring' selected='selected'> " . $text [ 'opt-ptring' ] . " </option> \n " ;
}
else {
echo " <option value='pt-ring'> " . $text [ 'opt-ptring' ] . " </option> \n " ;
}
if ( $ringback == " uk-ring " ) {
echo " <option value='uk-ring' selected='selected'> " . $text [ 'opt-ukring' ] . " </option> \n " ;
}
else {
echo " <option value='uk-ring'> " . $text [ 'opt-ukring' ] . " </option> \n " ;
}
if ( $ringback == " rs-ring " ) {
echo " <option value='rs-ring' selected='selected'> " . $text [ 'opt-rsring' ] . " </option> \n " ;
}
else {
echo " <option value='rs-ring'> " . $text [ 'opt-rsring' ] . " </option> \n " ;
}
Adding ru-ru locales (#2530)
* Translation of the menu (sent by Victor Kraft)
* ACL translate
* Backup translated
* App Fax translated (sent by Victor Kraft)
* App Adminer trnslated
* Resources translated (sent by Victor Kraft)
* App SIP Profiles translated
* ru-ru
* Call Block added
* ru-ru
* Update app_menu.php
* voicemails/app_languages.php locales ru-ru
voicemails/app_languages.php locales ru-ru
* app/vars/app_languages.php locales ru-ru
app/vars/app_languages.php locales ru-ru
* core: apps, authentication, databases, default_settings translate
* app/traffic_graph/app_languages.php adding locales ru-ru
app/traffic_graph/app_languages.php adding locales ru-ru
* app/time_conditions/app_languages.php adding locales ru-ru
app/time_conditions/app_languages.php adding locales ru-ru
* /app/system/app_languages.php adding locales ru-ru
/app/system/app_languages.php adding locales ru-ru
* /app/sip_status/app_languages.php adding locales ru-ru
* /app/settings/app_languages.php adding locales ru-ru
* /app/services/app_languages.php adding locales ru-ru
* /app/ring_groups/app_languages.php adding locales ru-ru
* /app/registrations/app_languages.php adding locales ru-ru
* /app/recordings/app_languages.php adding locales ru-ru
* /app/provision/app_menu.php adding locales ru-ru
* /app/pin_numbers/app_languages.php adding locales ru-ru
* Update app_languages.php
* /app/phrases/app_languages.php adding locales ru-ru
* /app/operator_panel/app_languages.php adding locales ru-ru
* core/groups translated
* /app/music_on_hold/app_languages.php adding locales ru-ru
* core/install translated
* core/menu translated
* /app/modules/app_languages.php adding locales ru-ru
* /app/meetings/app_menu.php adding locales ru-ru
* /app/log_viewer/app_languages.php adding locales ru-ru
* /app/ivr_menus/app_languages.php adding locales ru-ru
* /app/gateways/app_languages.php adding locales ru-ru
* /app/fifo_list/app_languages.php adding locales ru-ru
* core/notifications translated
* /app/fifo/app_languages.php adding locales ru-ru
* core/upgrade translated
* Update app_config.php
* core/user_settings translated
* Update app_languages.php
* Update app_menu.php
* Update app_languages.php
* core/users translated
* call_block translate fix
* Call Broadcast added
* call_block выклюено fix
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* themes translated
* /app/extensions/app_languages.php for locale ru-ru
* /app/exec/app_languages.php add locale ru-ru
* Update app_languages.php
* Update app_menu.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_languages.php
* Update app_menu.php
* add locales ru-ru /core/install/app_menu.php
* /app/emails/app_languages.php add locales ru-ru
* /app/edit/app_languages.php add locales ru-ru
* /app/dialplan_outbound/app_languages.php add lacales ru-ru
* app/devices translated
* /app/dialplan_inbound/app_languages.php add locales ru-ru
* call_center_active + call_centers
* /app/dialplan/app_languages.php add locales ru-ru
* /app/destinations/app_languages.php add locales ru-ru
* /app/database_transactions/app_languages.php add locales ru-ru
* /app/contacts/app_languages.php addlocales ru-ru
* Update app_languages.php
* Update app_languages.php
* /app/contacts/app_languages.php add locales ru-ru
* /app/conferences/app_languages.php add locales ru-ru
* /app/conference_profiles/app_languages.php add locales ru-ru
* /app/destinations/app_languages.php add locales ru-ru
* /app/destinations/app_languages.php add locales ru-ru
* /app/conferences/app_languages.php add locales ru-ru
* app/calls_active translated
* app/click_to_call translated
* app/calls_active label-opt fix transtation
* translated
* translated
* translate
* /app/voicemails/app_config.php addlocales ru-ru
* /app/voicemail_greetings/app_config.php add locales ru-ru
* /app/vars/app_config.php add locales ru-ru
* /app/traffic_graph/app_config.php add locales ru-ru
* /app/tones/app_config.php add locales ru-ru
* /app/time_conditions/app_config.php add locales ru-ru
* /app/tftp/app_config.php add locales ru-ru
* /app/system/app_config.php add locales ru-ru
* /app/sip_status/app_config.php addlocales ru-ru
* app/devices translated ru-ru
* app/devices translated ru-ru
* /core/menu/app_languages.php add locales ru-ru
* /app/contacts/app_languages.php add locales ru-ru
* /app/conferences/app_languages.php add locales ru-ru
* /app/voicemails/app_languages.php add locales ru-ru
* /app/conference_centers/app_languages.php add locales ru-ru
* /app/ring_groups/app_languages.php add locales ru-ru
* /app/ivr_menus/app_languages.php add locales ru-ru
* /app/xml_cdr/app_languages.php add locales ru-ru
* /resources/app_languages.php add locales ru-ru
* /app/conference_centers/app_languages.php add locales ru-ru
* call_flows
* /app/call_broadcast/app_languages.php add locales ru-ru
* /app/call_block/app_languages.php add locales ru-ru
* /app/call_block/app_languages.php add locales ru-ru
* /app/call_block/app_languages.php add locales ru-ru
* By now
* calls
* /app/call_flows/app_languages.php add locales ru-ru
* /app/system/app_languages.php add locales ru-ru
* /app/exec/app_languages.php add locales ru-ru
* /app/vars/app_menu.php add locales ru-ru
* /app/backup/app_languages.php add locales ru-ru
* /app/ring_groups/app_languages.php add locales ru-ru
* /app/calls/app_languages.php add locales ru-ru
* /app/call_centers/app_languages.php add locales ru-ru
* /app/call_broadcast/app_languages.php add locales ru-ru
* app/fax fix translate label-fax_send_channels
* /app/extensions/app_languages.php add locales ru-ru
* /app/xml_cdr/app_languages.php add locales ru-ru
* /app/ring_groups/app_languages.php add locales ru-ru
* /app/contacts/app_languages.php add locales ru-ru
* Fix default language select
* /app/contacts/app_languages.php add locales ru-ru
* Fix translations in app edit, extensions, fifo, gateways, music_on_hold, services, time_conditions, xml_cdr
* Replaced "звонки" to "вызовы" and fix sorting in menu for "Конференции"
* More replace "звонк"
* Fix translate
* app/xml_cdr replace translate for label-start_range, label-end_range
* app/xml_cdr replace translate label-destination, description_search and description-4
* Corrections
* Repalce "Порядковый номер" to "Приоритет"
* app/operator_panel replace translation label-call_group
2017-04-25 00:37:00 +02:00
if ( $ringback == " ru-ring " ) {
echo " <option value='ru-ring' selected='selected'> " . $text [ 'opt-ruring' ] . " </option> \n " ;
}
else {
echo " <option value='ru-ring'> " . $text [ 'opt-ruring' ] . " </option> \n " ;
}
2016-04-26 03:30:23 +02:00
if ( $ringback == " it-ring " ) {
echo " <option value='it-ring' selected='selected'> " . $text [ 'opt-itring' ] . " </option> \n " ;
}
else {
echo " <option value='it-ring'> " . $text [ 'opt-itring' ] . " </option> \n " ;
}
2019-03-05 20:19:10 +01:00
if ( $ringback == " de-ring " ) {
echo " <option value='de-ring' selected='selected'> " . $text [ 'opt-dering' ] . " </option> \n " ;
}
else {
echo " <option value='de-ring'> " . $text [ 'opt-dering' ] . " </option> \n " ;
}
2016-04-26 03:30:23 +02:00
if ( $ringback == " music " ) {
echo " <option value='music' selected='selected'> " . $text [ 'opt-moh' ] . " </option> \n " ;
}
else {
echo " <option value='music'> " . $text [ 'opt-moh' ] . " </option> \n " ;
}
echo " </select> \n " ;
echo " <br /> \n " ;
echo $text [ 'desc-ringback' ] . " \n " ;
echo " </td> \n " ;
echo " </tr> \n " ;
echo " <tr> \n " ;
echo " <td colspan='2' align='right'> \n " ;
echo " <br> " ;
2023-09-20 00:37:39 +02:00
echo " <button type='submit' class='btn btn-default'><i class='fas fa-phone fa-lg'></i> " . $text [ 'button-call' ] . " </button> \n " ;
2016-04-26 03:30:23 +02:00
echo " </td> \n " ;
echo " </tr> \n " ;
echo " </table> \n " ;
echo " <br><br> " ;
echo " </form> " ;
//show the footer
require_once " resources/footer.php " ;
2018-06-01 05:19:05 +02:00
2016-04-26 03:30:23 +02:00
?>