aboutsummaryrefslogtreecommitdiffstats
path: root/config/freeswitch_dev
diff options
context:
space:
mode:
authormcrane <mctch@yahoo.com>2009-08-11 02:03:31 -0600
committermcrane <mctch@yahoo.com>2009-08-11 02:03:31 -0600
commitcd5bee24927d619859854edce45596303cc1a0f1 (patch)
treecd2eb25f93b33290f203e30b5166042c027f2d0b /config/freeswitch_dev
parent76e0f9dc5184dfb72b66506f65fdbd84897b6c7d (diff)
downloadpfsense-packages-cd5bee24927d619859854edce45596303cc1a0f1.tar.gz
pfsense-packages-cd5bee24927d619859854edce45596303cc1a0f1.tar.bz2
pfsense-packages-cd5bee24927d619859854edce45596303cc1a0f1.zip
FreeSWITCH dev package make sure directory exists and add the option to hide the path on the fax edit page.
Diffstat (limited to 'config/freeswitch_dev')
-rw-r--r--config/freeswitch_dev/v_fax_edit.tmp36
1 files changed, 34 insertions, 2 deletions
diff --git a/config/freeswitch_dev/v_fax_edit.tmp b/config/freeswitch_dev/v_fax_edit.tmp
index 1548f3fb..603e72c4 100644
--- a/config/freeswitch_dev/v_fax_edit.tmp
+++ b/config/freeswitch_dev/v_fax_edit.tmp
@@ -46,6 +46,28 @@ if (isset($id) && $a_fax[$id]) {
$pconfig['faxemail'] = $a_fax[$id]['faxemail'];
$pconfig['faxdomain'] = $a_fax[$id]['faxdomain'];
$pconfig['faxdescription'] = $a_fax[$id]['faxdescription'];
+
+ if (!is_dir($v_storage_dir)) {
+ exec("mkdir ".$v_storage_dir);
+ }
+
+ if (!is_dir($v_storage_dir.'/fax/')) {
+ exec("mkdir ".$v_storage_dir."/fax/");
+ }
+
+ $faxfolder = $v_storage_dir.'/fax/'.$a_fax[$id]['faxextension'];
+ if (!is_dir($faxfolder)) {
+ exec('mkdir '.$faxfolder);
+ }
+ if (!is_dir($faxfolder.'/inbox/')) {
+ exec('mkdir '.$faxfolder.'/inbox/');
+ }
+ if (!is_dir($faxfolder.'/sent/')) {
+ exec('mkdir '.$faxfolder.'/sent/');
+ }
+ if (!is_dir($faxfolder.'/temp/')) {
+ exec('mkdir '.$faxfolder.'/temp/');
+ }
}
clearstatcache(); //clear file status cache
@@ -550,7 +572,12 @@ build_menu();
<span class="vexpl"><span class="red"><strong>Inbox</strong></span>
</td>
<td align='right'>
- <b>location:</b> <?php echo $dir_fax_inbox; ?>
+ <?php
+ if ($v_path_show) {
+ echo "<b>location:</b> ";
+ echo $dir_fax_inbox;
+ }
+ ?>
</td>
</tr>
</table>
@@ -636,7 +663,12 @@ build_menu();
<span class="vexpl"><span class="red"><strong>Sent</strong></span>
</td>
<td align='right'>
- <b>location:</b> <?php echo $dir_fax_sent; ?>
+ <?php
+ if ($v_path_show) {
+ echo "<b>location:</b> ";
+ echo $dir_fax_sent;
+ }
+ ?>
</td>
</tr>
</table>