projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0b457a4
)
Images.php
author
Alan Knowles
<alan@akbkhome.com>
Tue, 26 Feb 2013 12:58:29 +0000
(20:58 +0800)
committer
Alan Knowles
<alan@akbkhome.com>
Tue, 26 Feb 2013 12:58:29 +0000
(20:58 +0800)
Images.php
patch
|
blob
|
history
diff --git
a/Images.php
b/Images.php
index
2d32009
..
422bf9b
100644
(file)
--- a/
Images.php
+++ b/
Images.php
@@
-79,9
+79,15
@@
class Pman_Core_Images extends Pman
} else if (!empty($bits[0]) && $bits[0] == 'events') {
$popts = PEAR::getStaticProperty('Pman','options');
} else if (!empty($bits[0]) && $bits[0] == 'events') {
$popts = PEAR::getStaticProperty('Pman','options');
-
+ $ev = DB_DAtaObject::Factory('events');
+ if (!$ev->get($bits[1])) {
+ die("could not find event id");
+ }
//header ('Content-Type: image/jpeg');
//header ('Content-Type: image/jpeg');
- if(!empty($bits[2]) && $bits[2] == 'download'){
+ if(!empty($bits[0]) && $bits[2] == 'download'){
+
+
+
$file = "{$popts['event_log_dir']}/{$bits[1]}";
header("Content-Disposition: attachment; filename=\"".basename($file)."\";" );
ob_clean();
$file = "{$popts['event_log_dir']}/{$bits[1]}";
header("Content-Disposition: attachment; filename=\"".basename($file)."\";" );
ob_clean();