Brilliant Gallery: Incorrect main gallery folder path
astra - September 19, 2007 - 15:09
| Project: | Brilliant Gallery |
| Version: | 5.x-2.7 |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | minor |
| Assigned: | vacilando |
| Status: | closed |
Jump to:
Description
Installed and configured the latest version 5.x-2.6.
My file system path is: sites/default/files;
created and set the Path to the main gallery folder: albums;
created my gallery direction 2007_happy_new_year in the folder albums;
upload some pictures to folder 2007_happy_new_year.
I tried using the tag in a node: [bg|2007_happy_new_year], but it didn't work, just got message: "Incorrect main gallery folder path".
My setings not correct? Or something wrong?

#1
I'd say you have forgotten to remove a slash at the beginning of at the end of the path "albums" on the BG settings page. Can you re-check?
Do you have a link to the page so that I can see the HTML?
#2
On the page admin/settings/brilliant_gallery, my "Path to the main gallery folder" is "albums" without a slash. The HTML is just the tag in the body of the node (http://www.shenzhou.nl/drp5demo/node/2):
[bg|2007_happy_new_year]#3
This is weird. As you can see in http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/brilliant_g...
the error message you get can only be displayed if
if ( substr( $galleryfolder, strlen( $galleryfolder ) - 1, 1 ) == '/' or substr( $galleryfolder, 0, 1 ) == '/' ) {that means if the main gallery folder has a slash at the beginning or at the end..
#4
Ok, try replacing the line containing the error message in brilliant_gallery.module by this line:
return 'Incorrect main gallery folder path (' . $galleryfolder . '). Please fix it <a href="/admin/settings/brilliant_gallery">here</a>.';That should tell us what is the main gallery folder set to.
#5
My testing project:
http://www.tequilarace.net/projekt/educar/brilliant_gallery
The default directory for files is "filer" and I have created a subdir called "bilder"
So I entered just "bilder" in the Brilliant Gallery config.
When you enter the Brilliant Gallery it tries to get the images from:
http://www.tequilarace.net/filer/bilder
Not from the correct:
http://www.tequilarace.net/projekt/educar/filer/bilder
Why?
#6
Yes. After replaced the line (you mentioned at #4) in brilliant_gallery.module by this line:
return 'Incorrect main gallery folder path (' . $galleryfolder . '). Please fix it <a href="/admin/settings/brilliant_gallery">here</a>.';the gallery show up. see http://www.shenzhou.nl/drp5demo/node/2
Is this a right solution?
#7
Yes, it works, but it's not the code that fixed it :-)
The code I gave you would give us a richer error message so that we would know what's wrong.
As it turns out, there's no error msg and the gallery works.
My hypothesis is that you have caching switched on, or that somewhere else an old setting / content was stored. Once you changed the module (by improving the error message), you made the cache to refresh, and it worked normally. No idea. But it was definitely not a bug this time.
Enjoy!
#8
Yes, I agree with you. I updated from old version to this new version and the cache not to be refreshed in the beginning. Thanks for your explaination!
#9
fuzzion - what's the file system path set in your /admin/settings/file-system
I'm guessing that in order to use 'filer' as the main file folder, then you should have it set to
projekt/educar/filer
And yes, you set just
bilder
in the BG settings.
Also, can you please allow access for anonymous for BG, otherwise I cannot see the gallery on your page. Thanks.
#10
Using 'filer' as main file folder is correct, since the Drupal root directory is www.tequilarace.net/projekt/educar
The file system path in admin/settings/file-system is 'filer'
The file system works fine though, you can't change the path to 'projekt/educar/filer', the dir does not exists it says.
And thats true because that would be 'projekt/educar/projekt/educar/filer'
Sorry for not allowing anonymous access to BG, thats fixed now.
Best Regards,
Johan
#11
Johan,
I've looked into this - seems like it is a problem for Drupal to automatically determine the installation folder, there are extensive discussions such as http://lists.drupal.org/archives/support/2006-03/msg00042.html but they do not lead to any clear solutions.
I have a thought though - edit the settings.php file for your Drupal installation. In there you will find
# $base_url = 'http://www.example.com'; // NO trailing slash!
Try uncommenting it and setting this to:
$base_url = 'http://www.tequilarace.net/projekt/educar'; // NO trailing slash!
Hopefully the paths will be OK then. Let me know.
Tomas
#12
Hi Thomas.
Uncommenting that line and changing the path did not solve the problem.
I will read the discussions about the path problem with Drupal.
#13
Problem fixed with Brilliant Gallery 2.4
Thanks
#14
fuzzion, can you please try to install v2.7 and let me know whether the path issue has disappeared. The paths are now absolute; it should work properly.
#15
With 2.7, pictures are now not displayed anymore. With 2.6 they were working fine, but the albums were never refreshed (if I added a new picture to the folder). This seems to work now, but instead of pictures I get error icons.
No errors about incorrect path or so.
All albums located in folders like this /cms/files/albums/Japan_2004_001
I hope we can work it out cause I really like your module!
#16
ripclaw, can you please send me the URL to your gallery, then I would be able to solve it. If you can't, send me a private msg via http://quidne.vacilando.org/contact with the HTML output of your page, or at least of the gallery table in it. Don't worry, we'll get it sorted out.
Btw, as for the not refreshing when adding a new image - this is definitely due to Drupal's caching; you need to refresh the cache (or it has to expire) before the new images appear.
#17
2.7 works fine for me.
#18
I have some more questions but maybe I should start an new thread instead..
Which way is the best to modify the gallery?
I use div class:
[bg|mygallery]
Will you use pure css instead of tables in the future?
Would it be XHTML 1.0 Strict validated?
The gallery fails the validation at the moment.
I really like Brilliant Gallery so I hope these problems will be solved in the future :)
#19
<div class="gallery">[bg|mygallery]
</div>
#20
I am having the same problem as ripclaw. See the problem here: http://alabamia.com/forum/?q=node/1 . My images are in files/gallery and drupal is installed in a sub folder "forum".
#21
neal23, thanks for the bug report. The example helped me to identify the bug very fast. It happened because your site has not enabled Clean URLs. I have now updated the module so that it works also in that case. Please test version 2.8 and let me know whether it works all right for you.
Cheers,
Tomas
#22
I updated brilliant gallery on my site to the latest 2.8. I am still having the same problem. I then changed the site's urls to clean urls. That didn't make a difference. I then uploaded 2.7 back up with the clean urls and that didnt work for me. You can see it here: http://alabamia.com/forum/node/5
#23
neal23 - the html output of that page looks just the same as the one when clean URLs were disallowed. I think you need to clear your cache, then 2.7 will work with Clean URLs and 2.8 will work with or without them. Works? Let me know please.
Cheers,
Tomas
#24
Hi,
Maybe it's a stupid question, but I also have a problem and I can't fix this problem.
I have installed all required modeules that demands Brilliant Gallery. And it's working when I put in with block from administration panel. But if I want to put some galleries when I'm writting a page it does nothing.
My all pictures is in this directory: files/albums/album1
I set up in brilliant gallery administration panel path to the main gallery folder albums
So,
For example I want to write a page with some content and gallery:
"Some content, some content.............
[bg|albums/album1|6|60|random|6|#000000]"
And when I run the site, it shows the same line that I wrote in "page":
[bg|albums/album1|6|60|random|6|#000000]
What should I do, that it can run?
#25
motiejus,
1) If the tag shows in clear text, you forgot to perform step #3 from the installation at http://www.vacilando.eu/bg
2) if you set main gallery folder to be 'albums' in the BG settings, then you do not need to mention 'albums' in the tag. So in your case you need to use [bg|album1|6|60|random|6|#000000]
#26
Automatically closed -- issue fixed for two weeks with no activity.