I am running G2 inside Drupal 4.6.8. When my users try to go to see the pics they can get to the album list but when you click on an album to see individual pics nothing happens. \

When you click on a thumbnail from inside Drupal from the Random Image block, you don't get that picture displayed, instead you are taken to the album list.

I'm sure it's some sort of configuration problem in either Gallery or Drupal but where I have no idea. It worked initially on the integration so something has changed.

Any ideas?

Drupal v4.6.8
Gallery version = 2.1.2 core 1.1.0.2
PHP version = 4.4.2 apache

Comments

kiz_0987’s picture

Are you using URL Rewrite? If so, did you follow the instructions for setting up the rules?

rkdesantos’s picture

Yes, I am using rewrite. I have not changed the rules since they were set up.
And you set it up for me back in June. :-)

kiz_0987’s picture

Ahh, it must be right then ;-)

Has anything changed -- updated Gallery2 or Drupal for example? You were using 2.1.1 before, but it should still be OK. One option to try is to go into the URL Rewrite admin page of G2 and resave the settings. This worked for me once during an upgrade, but I was never able to understand why.

rkdesantos’s picture

The only changes I can recall have been the security updates to both... so it is now Gallery 2.1.2 and the fixes up to Drupal 4.6.9.

There was one other change made to allow Gallery Remote to work again at the suggestion of folks over at the Gallery support: I specified in Gallery the URL under config.php:

$gallery->setConfig('baseUri', 'http://www.afana.com/gallery2/main.php');

However, if I undo that change, it makes no difference to this problem.

I'm not planning on moving to Drupal 4.7 until sometime next month.

I resaved the URL rewrite settings without success.

rkdesantos’s picture

As a further follow-up, I would again note that the non-embedded form of gallery works fine. So, it is clearly something either in the Drupal gallery module or in the configuration for gallery interacting with the embedded version.

Here is the interesting part:

Disabling URL rewrite in Gallery doesn't seem to matter. However, in some instances whether it is enabled or not, if you click on an album's thumbnail more than once the second or third time you will get thru to the individual pictures.

Here's what is in the URL rewrite of my gallery install's .htaccess:

RewriteEngine On
RewriteBase /gallery2/
RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d [OR]
RewriteCond %{REQUEST_FILENAME} gallery\_remote2\.php
RewriteCond %{REQUEST_FILENAME} !/gallery2/main\.php$
RewriteRule . - [L]

RewriteCond %{THE_REQUEST} \ /gallery2/v/([^?]+)(\?.|\ .)
RewriteCond %{REQUEST_FILENAME} !/gallery2/main\.php$
RewriteRule . /gallery2/main.php?g2_view=core.ShowItem&g2_path=%1 [QSA,L]

-Rob
afana.com

Tanya S’s picture

Hey I am having the same problem with Drupal 4.7. I only just installed the Gallery today. It is working fine when I upload the images but when you click on the embedded album, nothing happens. I don't understand your last post though. No matter how many times I click on the album - nothing happens. And where abouts are you putting that code in?

kiz_0987’s picture

Rob, your site works fine for me. I can access all the albums and photos. Maybe it's a browser cookie issue -- try clearing your cookies.

Tanya S’s picture

Can someone also have a look at my gallery, as its not working for me. Its here http://www.girlsonfilmnetwork.org/?q=gallery

Thanks

rkdesantos’s picture

Hi Tanya,

I can verify that your site displays the same behaviour and it doesn't seem to matter how many times I click on the albums.

-Rob
afana.com

rkdesantos’s picture

Hmm, yes it seems to be working again today. I wonder if it is a cache problem with Drupal?

I cleared the cache the other day for unrelated reasons. I don't think it is a cookie problem since many of my users were having the same problem. I am going to e-mail several and have them tell me if it works for them now.

Tanya S’s picture

Thanks for checking. Mine still isn't working today. You mentioned you cleared the cache? I'm not sure how you do that - could you tell me please?

kiz_0987’s picture

Tanya S’s picture

Thanks but it doesn't make sense to me, I don't know how to get to the embedded view for a start!

rkdesantos’s picture

Tanya,

Do you have caching enabled on your Drupal site? Check the settings (not sure where it is now on 4.7). Some modules automatically clear the cache, others have an option to do it. Again, changes were made in 4.7 that I may not be familiar with. I cleared mine in the banner module since I changed the banner adverts.

kiz_0987's link is referring to the .htaccess file on the server in the Gallery directory (whatever you named that). Do you have ftp or shell access to your site?

Kiz,

So far the users are telling me the problem is resolved on my site. Not sure if disabling and re-enabling URL rewrite in Gallery fixed it or if flushing the cache did it.

Tanya S’s picture

Yeah Cache is enabled on my site. I don't know how to clear it though? do you mean just disable it?

I have a forum post about the problem I'm having here http://drupal.org/node/84554

I took someone elses advise in changing the name of my directory to gallery2 and its completely messed things up! It won't configure now. I'm using an FTP client and CPanel.

kiz_0987’s picture

Tanya S -- I recommend that you ignore the cache stuff for now. It is unlikely that it is the source of your problem.

I recommend you start by turning off (disable and uninstall) the URL Rewrite module in Gallery2 site admin. Then check to see if your embedded gallery works (eg if your use of "gallery" as the directory name is causing problems -- check the Gallery2 FAQ at http://codex.gallery2.org/index.php/Main_Page to see that just changing the name is not enough to move it to another dir).

If it works OK, then reinstall/enable the URL Rewrite module and go through the tests etc as given in the link above. When it talks about embedded it just means to access the page via drupal (instead of you non-embedded gallery). Do not set the "admin" rule, but the others are OK -- assuming you are using 4.7. The .htaccess file refered to in that page is your main Drupal one.

profix898’s picture

Component: User interface » User Interface / Theming
Status: Active » Closed (fixed)

Drupal 4.6 is no longer supported (and/or issue is irrelevant for the current version). Closing.