Merge pull request #787 from akretion/fix-upload-path
fixes bug #786 per_page_uploads: incorrect file path if page is inside some directory
This commit is contained in:
+1
-1
@@ -449,7 +449,7 @@ module Precious
|
||||
@content = page.formatted_data
|
||||
@upload_dest = settings.wiki_options[:allow_uploads] ?
|
||||
(settings.wiki_options[:per_page_uploads] ?
|
||||
@name : 'uploads'
|
||||
"#{path}/#{@name}".sub(/^\/\//, '') : 'uploads'
|
||||
) : ''
|
||||
|
||||
# Extensions and layout data
|
||||
|
||||
@@ -155,7 +155,7 @@ $(document).ready(function() {
|
||||
fields: [
|
||||
{
|
||||
type: 'file',
|
||||
context: 'Your uploaded file will be accessible at /'+uploadDest+'/[filename]',
|
||||
context: 'Your uploaded file will be accessible at<br>/'+uploadDest+'/[filename]',
|
||||
action: baseUrl + '/uploadFile'
|
||||
}
|
||||
],
|
||||
|
||||
Reference in New Issue
Block a user