aboutsummaryrefslogtreecommitdiffstats
path: root/doc/hook/get_photo.bb
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2016-10-17 22:09:41 -0700
committerzotlabs <mike@macgirvin.com>2016-10-17 22:09:41 -0700
commit17091bd38c4e4e5d8b1812dd1d9efeffe0046d02 (patch)
tree74a4d72846767c58d26b113b14de3da4dd0fb0c0 /doc/hook/get_photo.bb
parent437aa168d136db2c782ed2b366e411721f5f605c (diff)
downloadvolse-hubzilla-17091bd38c4e4e5d8b1812dd1d9efeffe0046d02.tar.gz
volse-hubzilla-17091bd38c4e4e5d8b1812dd1d9efeffe0046d02.tar.bz2
volse-hubzilla-17091bd38c4e4e5d8b1812dd1d9efeffe0046d02.zip
add get_photo hook to go along with get_profile_photo hook. This allows a plugin to over-ride the permissions for cover photos or insert a different photo in place of that requested
Diffstat (limited to 'doc/hook/get_photo.bb')
-rw-r--r--doc/hook/get_photo.bb14
1 files changed, 14 insertions, 0 deletions
diff --git a/doc/hook/get_photo.bb b/doc/hook/get_photo.bb
new file mode 100644
index 000000000..eaf3beffb
--- /dev/null
+++ b/doc/hook/get_photo.bb
@@ -0,0 +1,14 @@
+[h2]get_photo[/h2]
+
+Called when fetching the content of photos (except for profile photos) in mod_photo.
+
+
+Hook arguments:
+
+'imgscale' => integer resolution requested
+'resource_id' => resource_id of requested photo
+'photo' => array of matching photo table rows after querying for the photo
+'allowed' => whether or not access to this resource is allowed
+
+
+