aboutsummaryrefslogtreecommitdiffstats
path: root/core/js
diff options
context:
space:
mode:
Diffstat (limited to 'core/js')
-rw-r--r--core/js/js.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/core/js/js.js b/core/js/js.js
index 1bd650bb6b8..21466a809b2 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -154,6 +154,12 @@ OC={
$('head').append(style);
}
},
+ basename: function(path) {
+ return path.replace(/\\/g,'/').replace( /.*\//, '' );
+ },
+ dirname: function(path) {
+ return path.replace(/\\/g,'/').replace(/\/[^\/]*$/, '');;
+ }
/**
* do a search query and display the results
* @param query the search query