UCP downloads not working

We have recently upgraded to FreePBX 12 with the UCP module installed. We are not able to download the call recordings. The preview of the call is working in PC operating systems but not he mac (which our environment primarily is). The link opens a blank tab that executes nothing. the URL is MYURL/ucp/?quietmode=1&module=cdr&command=download&msgid=1421858922_20164&type=download&format=gsm&ext=7895http://sip.domain.com/ucp/?

I also wanted to add that we are able to download the calls from both the CDR Reports as well as the older UCP interface. It is only the new UCP that we are unable to download the recordings from.

This may not be related, but I’ve had issues uploading recordings using IE. Works fine in Firefox. Might be something to check.

I have attempted in IE, Chrome, Safari and Firefox on a Mac and PC OS. Regardless of the browser I am using the issue is always the same. When clicking the download link, a separate tab opens with the above URL, then nothing happens. The page is blank and there is no file sent to the downloads folder, no option to open, save or run. Thank you for the help though. If you have any other ideas I am open to suggestions.

I have found out that if I change the “format=gsm” to “format=wav” in the URL the gsm file will download. It seems that the issue is that particular part of the statement. I am curious if there is a way to permanently modify the output URL to always have the format equal to wav regardless of what the file type is of the downloadable recording?

Does the /etc/asterisk/voicemail.conf file have a “format=…” statement? In the FreePBX configuration this would be under Voicemail Admin | Settings.

This won’t help with why you get the popup, but it might help change the file-type to WAV.

Thank you for the assistance but the format= is not located in the voicemail.conf file. I am not sure if my posting is clear but I am attempting to modify the URL that is populated from the call history option within the user control panel.

Try editing the file /var/www/html/admin/modules/voicemail/ucp/views/mailbox.php. Change “gsm” to “wav” as shown below:

<a class="download" alt="<?php echo _('Download');?>" href="?quietmode=1&amp;module=voicemail&amp;command=download&amp;msgid=<?php echo $message['msg_id']?>&amp;format=gsm&amp;ext=<?php echo $ext?>" target="_blank">

to

<a class="download" alt="<?php echo _('Download');?>" href="?quietmode=1&amp;module=voicemail&amp;command=download&amp;msgid=<?php echo $message['msg_id']?>&amp;format=wav&amp;ext=<?php echo $ext?>" target="_blank">

Thank you for the helpful hint but it is not the solution to my issue. The voicemail/ucp/views/mailbox.php is already in a format=wav. It is the call recording that I am having issues with.

Not sure how I missed this was related to call recordings…

Have you tried changing the “Call Recording Format” to WAV under Advanced Settings?

We are intentionally using the GSM format due to its compression ability. The WAV format is substantially larger recordings and for compliance reasons we are required to record all calls across 2000 agents all day everyday. We keep the recordings for as long as our allotted space allows. The greater the compression the further back we can go in our recordings. I need only to have the URL read as a wav format. I have attempted to modify quite a few php files in the /var/www/html/admin/modules/ucp directory. I had thought I had found the resolution to my issue in a Ucp.class.php file but actually broke the UCP. So back to square one.

So I changed my “Call Recording Format” to gsm and was able to reproduce exactly what you are seeing.

I was able to download the gsm file by editing the file /var/www/html/admin/modules/cdr/ucp/views/view.php. I changed “<?php echo $call['recordingformat']?>” to “wav” as shown below:

<a class="hidden-xs download" alt="<?php echo _('Download');?>" href="?quietmode=1&amp;module=cdr&amp;command=download&amp;msgid=<?php echo $call['niceUniqueid']?>&amp;type=download&amp;format=<?php echo $call['recordingformat']?>&amp;ext=<?php echo $_REQUEST['sub']?>" target="_blank">

to

<a class="hidden-xs download" alt="<?php echo _('Download');?>" href="?quietmode=1&amp;module=cdr&amp;command=download&amp;msgid=<?php echo $call['niceUniqueid']?>&amp;type=download&amp;format=wav&amp;ext=<?php echo $_REQUEST['sub']?>" target="_blank">

It almost seems like the browser (I tested multiple) doesn’t know what to do with the gsm file. Oh well, maybe one of the freepBX gurus has a better fix. Don’t forget to make a good backup of the real files just in case.

That was the exact line of code I was looking for. I had located a few that I thought were the same function and the change caused the GUI to stop functioning completely. We use quicktime to handle the playback functionality after download. Thank you for the help, you are a life saver.