- Timestamp:
- 06/26/07 19:22:35 (6 years ago)
- Files:
-
- modules/branches/2.3/recordings/module.xml (modified) (2 diffs)
- modules/branches/2.3/recordings/page.recordings.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
modules/branches/2.3/recordings/module.xml
r4186 r4227 2 2 <rawname>recordings</rawname> 3 3 <name>Recordings</name> 4 <version>3.3. 1.1</version>4 <version>3.3.3</version> 5 5 <candisable>no</candisable> 6 6 <type>setup</type> … … 8 8 <description>Creates and manages system recordings, used by many other modules (eg, IVR).</description> 9 9 <changelog> 10 *3.3.1.1* added candisable = no for module admin 10 *3.3.3* fixed bug not able to save recorded message from *77 featurecode 11 *3.3.2* use urlencode/decode in the crypt functions 12 *3.3.1.1* added candisable = no for module admin, and new play button 11 13 *3.3.1* Fix mp3 upload bug (#1764) 12 14 *3.3* Stop assuming that files being uploaded are .wav's, also highlight the correct format for files to be uploaded in. modules/branches/2.3/recordings/page.recordings.php
r4147 r4227 21 21 $usersnum = isset($_REQUEST['usersnum'])?$_REQUEST['usersnum']:''; 22 22 $sysrec = isset($_REQUEST['sysrec'])?$_REQUEST['sysrec']:''; 23 $suffix = isset($_REQUEST['suffix'])?$_REQUEST['suffix']:'wav'; 23 $suffix = isset($_REQUEST['suffix']) && trim($_REQUEST['suffix'] != "") ? $_REQUEST['suffix'] : 'wav'; 24 25 $astsnd = isset($asterisk_conf['astvarlibdir'])?$asterisk_conf['astvarlibdir']:'/var/lib/asterisk'; 26 $astsnd .= "/sounds/"; 27 24 28 if (empty($usersnum)) { 25 29 $dest = "unnumbered-"; … … 45 49 break; 46 50 case "newsysrec": 47 $astsnd = isset($asterisk_conf['astvarlibdir'])?$asterisk_conf['astvarlibdir']:'/var/lib/asterisk';48 $astsnd .= "/sounds/";49 51 $sysrecs = recordings_readdir($astsnd, strlen($astsnd)+1); 50 52 if (recordings_add($sysrecs[$sysrec], $sysrecs[$sysrec])) { … … 60 62 // Clean up the filename, take out any nasty characters 61 63 $filename = escapeshellcmd(strtr($rname, '/ ', '__')); 62 if (!file_exists($ recordings_astsnd_path."custom")) {63 if (!mkdir($ recordings_astsnd_path."custom", 0775)) {64 echo '<div class="content"><h5>'._("Failed to create").' '.$ recordings_astsnd_path.'custom'.'</h5>';64 if (!file_exists($astsnd."custom")) { 65 if (!mkdir($astsnd."custom", 0775)) { 66 echo '<div class="content"><h5>'._("Failed to create").' '.$astsnd.'custom'.'</h5>'; 65 67 } 66 68 } else { 67 69 // can't rename a file from one partition to another, must use mv or cp 68 70 // rename($recordings_save_path."{$dest}ivrrecording.wav",$recordings_astsnd_path."custom/{$filename}.wav"); 69 exec("mv " . $recordings_save_path . "{$dest}ivrrecording.$suffix " . $ recordings_astsnd_path."custom/{$filename}.$suffix");71 exec("mv " . $recordings_save_path . "{$dest}ivrrecording.$suffix " . $astsnd."custom/{$filename}.$suffix"); 70 72 $isok = recordings_add($rname, "custom/{$filename}.$suffix"); 71 73
