I have what seems to be a common issue with BG; When creating a gallery BG finds the correct folder and creates the list of images, but no images are shown as thumbs or when clicking them.

I found the reason, however I do not know how to fix it.

a href="/index.phpsites/default/files/albums/dap/17-06-06_2250.jpg" rel="lightbox[335191]" title="17-06-06 2250">Only local images are allowed.

In my mind it "/index.php" should be replaced by /sites/ from both the href part and src part.
If index.php IS in fact correct, then you need to add a "/" behind it.

Can anyone with the same problem confirm this ?
How can I fix it?

CommentFileSizeAuthor
#17 brilliant_gallery.module.txt37.1 KBfusions
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

jostein’s picture

The tags messed up the < blockquote > in the post above so i am adding the src tag here:

src="/index.phpmodules/brilliant_gallery/image.php?imgp=RDpcZHJ1cGFsXHNpdGVz

jostein’s picture

Confirmed, the problem is the string "index.php" being added to the HREF tag and the SRC tag.

When i copied the automaticaly generated <ul> tag and removed "index.php" from the two url's everything worked fine.

Now, I can do that manualy on every single picture in the gallery, but... There must be some way in the code where it sais to add it?

Would love some help on this.

jostein’s picture

Title: BG error in source, links are wrong (missing / etc) » How to remove "index.php" from href/src tag when using [BG| ] tag? messes links up.
Vacilando’s picture

OK, you got me worried, so I've just downloaded a clean BG v6.2, my main folder is 'albums', in it there is a folder with images called '2007_Tomas' and this is what I wanted to display, so I created a new page (of course after enabling bg filter for that content type) and therein used tag [bg|2007_Tomas] ... and - without any trouble - you can see the result at http://lab.vacilando.eu/test

I am not sure why you have 'index.php' in there. What is your main gallery folder in settings? How does your tag look like? On what system are you? Localhost installations can be unpredictable due to path reasons, also Windows installs have often given us headaches. So you need to describe these..

jostein’s picture

Thanks for taking the time Vacilado :)

Im running Drupal 6 on IIS7, server is running Microsoft server 2008.
I just downloaded your new BG v6.2 and had the same issue there.

My albums are located in folder: sites/default/files/albums/
The album im trying to show for this example is located in ../albums/dap
My main gallery folder in settings is 'albums' (no slash, no ')

The tag i use in the page is: [bg|dap]
BG has been enabled for "full html" pages.

You say:
"Localhost installations can be unpredictable due to path reasons, also Windows installs have often given us headaches. So you need to describe these.."

Not sure what you mean by this. I am running everything on my own server, drupal, php, sql, the album folder etc.
Think maybe its IIS7 that is messing things up? Do you know anyone else that has tried using BG on IIS7?

naminder’s picture

has anyone got a solution yet? I have also installed this on version 6 and get same error.

jostein’s picture

More people are confirming the problem and more threads are created on the problem.

Will everyone with the error above (lease check your sourcecode and confirm this is your problem before posting) answer the following questions:

Drupal version?
BG version ?
PHP version?
Webserver?

What else can be relevant?

I have:
Drupal 6.2
BG 6.x-1.2
PHP 5.2.6
IIS 7 on Microsoft server 2008.

xaviercas’s picture

Hello,

I have a similar problem. None of the images show up because of the path such as:
<a href="/index.phpsites/default/files/ekkogallery/artcraft/octopus2.jpg" rel="lightbox[4936067]" title="octopus2"><img style="border:0" alt="" rel="lightbox" src="/index.phpsites/all/modules/brilliant_gallery/image.php?imgp=L2NsaWVudGRhdGEvd3d3L2NvbS9lL2Vra29jcmVhdGl2ZXMuY29tL3NpdGVzL2RlZmF1bHQvZmlsZXMvZWtrb2dhbGxlcnkvYXJ0Y3JhZnQvb2N0b3B1czIuanBn&imgw=65&imgh=86" /></a>
Running D6.4 and latest BG and Lightbox.
Thanks

pveeuk’s picture

Xaviercas,

Exactly same problem here !! :(.... thumbnails broken ...still can click on it and view the album images....

any solution pleaes???

thx

pv

aregan’s picture

Hi,

I'm seeing the very same issue using:

Drupal 6.4
BG 6.x-1.2
PHP 5.2.3
IIS on Microsoft server 2003.

An its related to the index.php been preappended to the link ... eg .... "/index.phpsites/default/files/albums/dap

Alan

fusions’s picture

Version: 6.x-1.1 » 5.x-4.4
Priority: Normal » Critical

Any idea on how to fix this?

i'm using Drupal 5.16 an BG 5.x-4.4

GaryA’s picture

I'm curious myself about this problem. For me BG 5.x-4.4 works fantastically on Win32, Apache, MySQL, PHP 5 from XAMPP and Drupal 5.15. Then I figured I'd move it to my production site which is UNIX, Apache 1.3.41, MySQL 5.0.67, PHP 5.2.6 , Drupal 5.15 and sure enough I get the black screen of death on the production site after testing it on my laptop web server where it worked great.

I'm about out of ideas at the moment but i have a feeling it might be a permissions issue becuase I keep getting the "Premature End of Script headers" in my Error Logs and a thing that says SoftException /home/mydir/sites/all/modules is writeable by group.

UPDATE: It really does look like mine is a permissions issue with Apache. I set all the perms on the sites/all/modules directory from the 775 they were at to 755 like it seemed to want but then my site went crazy so I had to turn it back to 775. At least at 755 it tried to execute the code.

UPDATE2: GOT MINE FIXED!!!!!! It turns out that my Production UNIX site described above was not allowing Image.php to run/be processed becuase of Apache Permission restrictions on the /sites/all/modules/brilliant_gallery directory. It was insisting on 755 and not 775 on all the directories all the way up the tree which I couldn't do because it whacked my site for some reason.

So I went about changing where Brilliant Gallery looks for Image.php, everyone's favorite crazy file. I went into BrilliantGallery.Module and edited the two main functions render_brilliant_gallery_manage and render_brilliant_gallery right around line 414 for the manage function and around 678 for the main galley render function.

I moved image.php to a directory CHMOD'ed to 755 where I knew PHP worked because I had another script there and right below those line in the functions listed above redefined the variable $ModulePath that defines where image.php is found to the place where I moved it. We use Clean URL's already so I didn't have to worry with the error checking for non clean ones. The Code that I put in was just a one liner right below the code I will show below in both functions.

     # Non-clean URLs need removing ?q=
      $modulepath = str_replace("?q=", "", $modulepath);

     //Change where Brilliant Gallery looks for image.php to let apache run PHP were it seems to like it
      $modulepath = "http://www.mysite.com/photogallery";

Also look for the above code in views.inc just for completeness.

haggins’s picture

I had a very similar problem:

There were no thumbs at the managment site and on my nodes I got only a black block. Looking at the code I tried a direct access to "http://localhost/rossini_drupal/sites/all/modules/brilliant_gallery/imag..." which resulted in a mysql-error an the image binary.

The failure is located in modules/brilliant_gallery/image.php on lines 106/108. For Drupal 6 you have to comment line 106 and outcomment line 108 AND to correct the cache_set function call to:

cache_set($bgcacheid, $my_data, 'cache', time() + $bgcachexpire);

Now it works and I'm looking forward to theme the output :)
Hope this helps someone.

I see a lot more bugs as i.e the bootstrap.inc gets not included and so db-caching is always activated no matter what you configured. Probably this will cause a lot more problems...so I changed to the Image module.

fusions’s picture

I'm still having problems with this....

http://nidak.jennie-lovers.be/index.php?q=node/21

It's still adding index.php before the link....

please help me!!

fusions’s picture

Version: 5.x-4.4 » 6.x-3.0

Installed drupal 6.13 on my space... still no images on brialliant gallery!

Please help

http://nieuw.jennie-lovers.be/index.php?q=node/5

fusions’s picture

how can i just add a ? between the index.php and modules.... url??

<a href="http://nieuw.jennie-lovers.be/index.phpmodules/brilliant_gallery/image.php?imgp=L2hvbWUvaHR0cGQvdmhvc3RzL2plbm5pZS1sb3ZlcnMuYmUvc3ViZG9tYWlucy9uaWV1dy9odHRwZG9jcy9maWxlcy9hbGJ1bXMvQ2hvY29sYWRldmVya29vcDIwMDcvY2hvY29sYWRlIDIwMDctMV9qcGcuanBn&imgw=1000&imgh=750"><img style="border: 0; margin:0px; padding:0px;" alt="" src="http://nieuw.jennie-lovers.be/index.phpmodules/brilliant_gallery/image.php?imgp=L2hvbWUvaHR0cGQvdmhvc3RzL2plbm5pZS1sb3ZlcnMuYmUvc3ViZG9tYWlucy9uaWV1dy9odHRwZG9jcy9maWxlcy9hbGJ1bXMvQ2hvY29sYWRldmVya29vcDIwMDcvY2hvY29sYWRlIDIwMDctMV9qcGcuanBn&imgw=150&imgh=113" /></a>
fusions’s picture

Status: Active » Patch (to be ported)
FileSize
37.1 KB

I've found a solution!

Just rename file to brilliant_gallery.module and upload to your website!

ashok7067’s picture

Hi.. I also have the same problem. I use version 3.6. I tried what fusion has told. It was showing error. Still no solution. Please someone help. I run in IIS, Windows 2008 server.