diff options
author | zotlabs <mike@macgirvin.com> | 2018-05-15 16:51:04 -0700 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2018-05-15 16:51:04 -0700 |
commit | aac5fd96cc9ea03a329234f6b2bd8b12a0f4ae5f (patch) | |
tree | d84109a6b10d470235a279195f5218ae160ebedc /Zotlabs/Module/Linkinfo.php | |
parent | 16930c1c54ef4bb3077bb868a366c0165eb33fae (diff) | |
download | volse-hubzilla-aac5fd96cc9ea03a329234f6b2bd8b12a0f4ae5f.tar.gz volse-hubzilla-aac5fd96cc9ea03a329234f6b2bd8b12a0f4ae5f.tar.bz2 volse-hubzilla-aac5fd96cc9ea03a329234f6b2bd8b12a0f4ae5f.zip |
provide function to fetch photo contents from url
Diffstat (limited to 'Zotlabs/Module/Linkinfo.php')
-rw-r--r-- | Zotlabs/Module/Linkinfo.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Zotlabs/Module/Linkinfo.php b/Zotlabs/Module/Linkinfo.php index 3f58f3e01..f0d62b5e0 100644 --- a/Zotlabs/Module/Linkinfo.php +++ b/Zotlabs/Module/Linkinfo.php @@ -55,10 +55,10 @@ class Linkinfo extends \Zotlabs\Web\Controller { $h = explode("\n",$result['header']); foreach ($h as $l) { list($k,$v) = array_map("trim", explode(":", trim($l), 2)); - $hdrs[$k] = $v; + $hdrs[strtolower($k)] = $v; } - if (array_key_exists('Content-Type', $hdrs)) - $type = $hdrs['Content-Type']; + if (array_key_exists('content-type', $hdrs)) + $type = $hdrs['content-type']; if($type) { $zrl = is_matrix_url($url); if(stripos($type,'image/') !== false) { |