]> source.dussan.org Git - nextcloud-server.git/commitdiff
Implemented ace-edtior as an app. Basic file editing and saving supported.
authorTom Needham <needham.thomas@gmail.com>
Wed, 28 Sep 2011 14:15:04 +0000 (15:15 +0100)
committerTom Needham <needham.thomas@gmail.com>
Wed, 28 Sep 2011 14:15:04 +0000 (15:15 +0100)
.htaccess
files/js/fileactions.js
lib/filesystem.php

index 181248267559e377dbac74e01b395cbc215558f6..ced9ae652d2c345152619b3ef29cbdbbf0ed873e 100644 (file)
--- a/.htaccess
+++ b/.htaccess
@@ -1,7 +1,7 @@
-ErrorDocument 404 //owncloud/core/templates/404.php
+ErrorDocument 404 /core/templates/404.php
 <IfModule mod_php5.c>
-       php_value upload_max_filesize 512M
-       php_value post_max_size 512M
-       SetEnv htaccessWorking true
+php_value upload_max_filesize 512M
+php_value post_max_size 512M
+SetEnv htaccessWorking true
 </IfModule>
 Options -Indexes
index 4ff8562fef3bcbf3af21f0b6bced2d8bf8042ee5..5d31af40376ee11a4a084344c3470748349616a3 100644 (file)
@@ -135,6 +135,9 @@ FileActions.register('all','Delete',function(){return OC.imagePath('core','actio
 FileActions.register('all','Rename',function(){return OC.imagePath('core','actions/rename')},function(filename){
        FileList.rename(filename);
 });
+FileActions.register('text','Edit',function(){return OC.imagePath('core','actions/rename')},function(filename){
+       window.location='/apps/editor/index.php?file='+filename+'&dir='+$('#dir').val();
+});
 
 //FileActions.setDefault('all','Download');
 
@@ -142,4 +145,4 @@ FileActions.register('dir','Open','',function(filename){
        window.location='index.php?dir='+$('#dir').val()+'/'+filename;
 });
 
-FileActions.setDefault('dir','Open');
+FileActions.setDefault('dir','Open');  
index b97fa8d784a12e34b86607d89caab0d107d66b50..f84cda20eac690a064404e9cfe43bdde3590273d 100644 (file)
@@ -441,6 +441,10 @@ class OC_Filesystem{
                return $files;
                
        }
+       
+       static public function update_session_file_hash($sessionname,$sessionvalue){
+               $_SESSION[$sessionname] = $sessionvalue;
+       }
 
        /**
         * abstraction for running most basic operations