aboutsummaryrefslogtreecommitdiffstats
path: root/include/attach.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-03-14 22:02:28 -0700
committerMario Vavti <mario@mariovavti.com>2017-03-29 13:44:17 +0200
commitfa5115b3ed017f6aa22c99cad563de3934b171c2 (patch)
treec991038cb13bfbbbead26a6a66f82f26b38e1e0b /include/attach.php
parentec5e1067bc0a949ceea7e28dbf11873e693b2586 (diff)
downloadvolse-hubzilla-fa5115b3ed017f6aa22c99cad563de3934b171c2.tar.gz
volse-hubzilla-fa5115b3ed017f6aa22c99cad563de3934b171c2.tar.bz2
volse-hubzilla-fa5115b3ed017f6aa22c99cad563de3934b171c2.zip
add os_path and display_path to photos, fix some issues with multiple path separators after cloud/nickname in the content field of attach and photos
Diffstat (limited to 'include/attach.php')
-rw-r--r--include/attach.php9
1 files changed, 4 insertions, 5 deletions
diff --git a/include/attach.php b/include/attach.php
index f8227fb4b..cbcdbc399 100644
--- a/include/attach.php
+++ b/include/attach.php
@@ -702,11 +702,10 @@ function attach_store($channel, $observer_hash, $options = '', $arr = null) {
$os_relpath .= $folder_hash . '/';
}
- $os_relpath .= $hash;
-
- // not yet used
- $os_path = ltrim($os_relpath,'/');
+ $os_relpath .= $hash;
+ $os_relpath = ltrim($os_relpath,'/');
+ $os_path = $os_relpath;
$display_path = $pathname . '/' . $filename;
if($src)
@@ -811,7 +810,7 @@ function attach_store($channel, $observer_hash, $options = '', $arr = null) {
if($is_photo) {
- $args = array( 'source' => $source, 'visible' => $visible, 'resource_id' => $hash, 'album' => basename($pathname), 'os_path' => $os_basepath . $os_relpath, 'filename' => $filename, 'getimagesize' => $gis, 'directory' => $direct, 'options' => $options );
+ $args = array( 'source' => $source, 'visible' => $visible, 'resource_id' => $hash, 'album' => basename($pathname), 'os_syspath' => $os_basepath . $os_relpath, 'os_path' => $os_path, 'display_path' => $display_path, 'filename' => $filename, 'getimagesize' => $gis, 'directory' => $direct, 'options' => $options );
if($arr['contact_allow'])
$args['contact_allow'] = $arr['contact_allow'];
if($arr['group_allow'])