I have an issue in my website as follows
Avatars are displaying properly but when iam trying to display images using any image plugin it is not getting displayed
Detailed information
following is the HTML code iam getting for the images which are not displaying
(there is no issue with the above HTML code, it seems correct )
while looking at firebug, clicking on the src location of image file iam getting someting as follows <!--?xpacket begin='' id='W5M0MpCehiHzreSzNTczkc9d'?--> insted of orginal image.
Your suggestions are higlhy appreciated ...
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by Raül Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.
- Juho Jaakkola@juho.jaakkola
Juho Jaakkola - 0 likes
- Tommy@letom
Tommy - 0 likes
- Juho Jaakkola@juho.jaakkola
Juho Jaakkola - 0 likes
- Tommy@letom
Tommy - 0 likes
- Juho Jaakkola@juho.jaakkola
Juho Jaakkola - 0 likes
- Tommy@letom
Tommy - 0 likes
- Juho Jaakkola@juho.jaakkola
Juho Jaakkola - 0 likes
- Tommy@letom
Tommy - 0 likes
- Al-ayam@sintu
Al-ayam - 0 likes
You must log in to post replies.Why are you using an action to display an image? Actions are meant for saving data. (http://mywebsite/elgg/action/blog/save etc.)
@Juho, yes we can change it to views folder , but that is not the issue for displaying image, can u trace out anything
It's impossible to say what is wrong without seeing the contents of the file that serves the images.
there no issue with the plugin, the image displays properly when iam checked with the fresh installation of new version of elgg copy, but iam working on current copy i need to correct in the same.
I think some fault some where occured in coding when i added new modules.
Can u explain how this image is diaplaying, then i can traceout the error as myself.
I have no idea what the code in your plugin is doing so it's impossible to tell what's wrong about it.
You're asking help for making a rather complicated feature. You cannot expect anyone to voluntarily spend their time to fix it if you're not even willing to share the code that you're working on.
@Juho
It is not the problem of posting coding,
Iam a programmer and i can assure, some blocks code have no issues, then what will be the profit if iam posting that code blocks here, that will voluntarily spend the readers time you said.
i already informed in post that the plugin have no issues, becuse it is developed by people who have more expirience than me in elgg, moreover i checked it completely, FYI information it is working fine in a fresh installation of new copy of elgg(there is no subjected issue in that). Again if iam posting the code iam working, how can anyone voluntarily spend their time to read 1000+ line of coding there.
Hope, if you cannot trace it out, may some others can, becuse devlopment team can find the exceptions easily, i hope some one from dev team will respond to this issue.
FYI coding of view.php are as follows
$file_guid = (int) get_input("file_guid");
$file = get_entity($file_guid);
if ($file) {
$filename = $file->originalfilename;
$mime = $file->mimetype;
header("Content-type: $mime");
header("Content-Disposition: inline; filename=\"$filename\"");
$readfile = new ElggFile($file_guid);
$readfile->owner_guid = $file->owner_guid;
$contents = $readfile->grabFile();
echo $contents;
exit;
}
Thanks
So this code is from the bundled file plugin and it stopped working once you enabled some non-bundled plugins?
I traced out the error, It is in old bookmark plugin, when i changed the book mark plugin of 1.18.11 to 1.18.16 its working fine
Tommy,
I used the same file uploading like file plugin and also used the same code like in file's download.php page.
But still I got the error " The image cannot be displayed because it contain errors".
How can i solve this problem?
Thanks