Skip to content

Commit

Permalink
Use filePathUrl instead of filePath (#97)
Browse files Browse the repository at this point in the history
  • Loading branch information
dneukirchen authored and laoneo committed Feb 24, 2017
1 parent 569dd32 commit 3659173
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@
computed: {
/* Get the item url */
itemUrl() {
const filePath = Joomla.getOptions('com_media').filePath || 'images';
// TODO should we use relative urls here?
const fileBaseUrl = Joomla.getOptions('com_media').fileBaseUrl || '/images';
return '/' + filePath + this.item.path;
return fileBaseUrl + this.item.path;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
$config = array(
'apiBaseUrl' => JUri::root() . 'administrator/index.php?option=com_media&format=json',
'filePath' => $params->get('file_path', 'images'),
'fileBaseUrl' => JUri::root() . $params->get('file_path', 'images'),
'allowedUploadExtensions' => $params->get('upload_extensions', ''),
'maxUploadSizeMb' => $params->get('upload_maxsize', 10),
);
Expand Down
Loading

0 comments on commit 3659173

Please sign in to comment.