Active
Project:
IMCE_Gallery
Version:
5.x-1.x-dev
Component:
Code
Priority:
Critical
Category:
Support request
Assigned:
Reporter:
Created:
5 Aug 2007 at 12:38 UTC
Updated:
26 Nov 2007 at 21:21 UTC
i have installed IMCE and IMCE gallery, and i try to create a gallery and upload photo using "personal files".
After uploaded, so i add it into my gallery but i click on the gallery i created, the photo display is just nothing while i point my mouse on it i can see this "http://www.mydomain.com/?# i think this url is couse the pic not showing properly.
2nd thing is when i point my mouse "back to gallery" it show me "http://user/1/imce_gallery" may i know what's wrong with it?
Please help
Comments
Comment #1
dex002 commentedI have the same problem. Just placeholders instead of images.
Comment #2
lucas20 commentedSame problem, but the photos display if it is my own gallery, but if someone else is looking then the same error as above.
Comment #3
jwilde commentedqucik hack:
change the function theme_gallery_items to:
function theme_gallery_items($rows) {
global $base_path;
$userid = arg(1);
$output = '';
$img_num=0;
$a = 0;
foreach($rows as $filename) {
$path = 'files' . '/u' . $userid . '/' . $filename;
jim
Comment #4
psytwo commentedThanks for your post Jim, it didn't quite work for me at first (I know next to nothing about php!) but after a little tweaking I think I got it right. This is what I did and it fixed the problems I was having, hope it helps someone cos this drove me pretty crazy!
I am running Drupal 5, with the IMCE (5.x-1.0) and IMCE_Gallery (5.x-1.x-dev) module installed. I then changed the amount of galleries a user can create to 3(default was zero?) in IMCE Gallery Settings, other than that the rest was all left with the default settings.
The main problems I had was that when I went into a user's gallery, no images would display. The stylesheet seemed to load but the images wern't there even though I had definitely uploaded some images to that gallery.
Here's what I did to fix this:
My original function function theme_gallery_items in modules/imce_gallery/imce_gallery.module file looked like this (starts at line 359):
I then added $userid = arg(1); just under the existing $output = ''; line and replaced the line $path = $folder . '/' . $filename; with $path = 'files' . '/u' . $userid . '/' . $filename;
So basically it looks like this:
Now when I go into a user's gallery, the thumbs show up. I'm also able to click on the thumbs and bring up the original image. w00t, she just needs some decent styling now...
The next problem I had was that the Back to Gallery link didn't work at all, it pointed to http://user/9/imce_gallery which ain't right. To tell the truth, I thought about it and figured there was no point in even having this Back to Gallery link anyways, the user should know that he/she can go back using the profile tabs so in the end I just commented out the line:
so
I ran http://www.yourhost.com/update.php to update the modules, and all was well.
Adios!
Comment #5
sdsheridanI resolved the "back" link differently (and it works). I declared
up top in the function, and then further down, changed the code to read
The rest of the code stayed the same, and the back link now works.