Skip to content

Commit

Permalink
added debug path feature
Browse files Browse the repository at this point in the history
  • Loading branch information
Offerel committed Feb 17, 2018
1 parent f17270a commit b5d0312
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 15 deletions.
10 changes: 0 additions & 10 deletions client.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,6 @@ window.rcmail && rcmail.addEventListener('init', function(evt) {

var fbutton = $("#compose-attachments").contents().find("a.button");
fbutton.after("<a class='button' tabindex='2' href='#' onclick='cform();'>" + rcmail.env.elbutton + "</a>");
/*
//var menu = rcm_callbackmenu_init({menu_name: 'storagemenu', menu_source: '#storage_sub'});
$(stbutton).on("contextmenu", function(e)
{
rcm_show_menu(e, this, stbutton, menu);
});
*/
});

function save_one()
Expand All @@ -34,10 +26,8 @@ function add_note()
if (title == null || title == "") {
return;
} else {
//txt = "Hello " + title + "! How are you today?";
rcmail.http_post('storage/add_note', '_title=' + urlencode(title) + '&_tags=' + urlencode(tags));
}
//document.getElementById("demo").innerHTML = txt;
}

function dmessage(response)
Expand Down
14 changes: 9 additions & 5 deletions elfinder/php/connector.roundcube.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<?php

error_reporting(0); // Set E_ALL for debuging
// This part is needed to use the Roundcube Session for authentication. Don't remove this !!!
// ------------------------------------------------------------------------------------------
Expand Down Expand Up @@ -38,6 +37,8 @@
// Roundcube authentication finished. You can use now the $path variable as path for elFinder.
// ------------------------------------------------------------------------------------------

if($rcmail->config->get('storage_debug'))
error_log("Calculated path: ".$path);

// elFinder autoload
require './autoload.php';
Expand All @@ -60,16 +61,19 @@ function access($attr, $path, $data, $volume, $isDir, $relpath) {
'driver' => 'LocalFileSystem', // driver for accessing file system (REQUIRED)
'path' => $path, // path to files (REQUIRED)
'uploadAllow' => array('all'),// Mimetype `image` and `text/plain` allowed to upload
'alias' => $storage_name,
'alias' => $storage_name,
'uploadOrder' => array('deny', 'allow'), // allowed Mimetype `image` and `text/plain` only
'accessControl' => 'access', // disable and hide dot starting files (OPTIONAL)
'tmbPath' => '/tmp',
'quarantine' => '/tmp'
//'tmbPath' => '/media/stick/www/html/tmb',
//'tmbURL' => '/tmb',
//'tmbCrop' => true,
//'imgLib' => 'gd',
//'tmbSize' => 48,
'quarantine' => '/tmp'
)
)
);

// run elFinder
$connector = new elFinderConnector(new elFinder($opts));
$connector->run();

0 comments on commit b5d0312

Please sign in to comment.