function sendFax($documentPath, $faxNumbersArray){ $from = sessionManager::curentUser('names'); $msg = date('j F Y H:i:s', time())."\n"; $msg.= count( $faxNumbersArray )." fax request sent by " . sessionManager::curentUser('names') ." :\nDocument URL : $documentPath\n\n"; foreach ($faxNumbersArray as $faxNumber){ $command = 'sendfax -f "'.sessionManager::curentUser('email').'" -R -r "'.$from.'" -c "Document" -x "To Company" -d "Recipient@'.$faxNumber.'" '.$documentPath; $system = system( escapeshellcmd( $command ), $retval ); $msg .= "Fax number: $faxNumber\n"; $msg .= "Command: $command\n"; $msg .= "Server response: $retval\n\n"; } $msg .= "=======================================================================\n\n"; error_log($msg,3,'logs/fax_log.txt'); }
ATTENZIONE: il tuo commento verrà prima moderato e se ritenuto idoneo sarà pubblicato
© 2007-2024 - ATTIVA WEB - Internet agency - P. iva 02645880739
Realizzazione siti internet Martina Franca, ecommerce Martina Franca
Via Giacomo Puccini 23 - 74015 Martina Franca (TA) - Privacy & Cookie Law