Installed Into Drupal OK, but No Links Work

jonwatson

Joined: 2009-08-11
Posts: 10
Posted: Tue, 2009-08-11 19:44

Hi All,

I can't figure out what I am missing. I have installed Gallery2 and the Gallery2 module for Drupal. The Installation tab tells me that everything is OK, yet there's no way to access the gallery at all except directly as a standalone app.

Quote:
PHP Memory Limit OK Your PHP is configured to limit the memory to 128M (memory_limit parameter in php.ini). This should be fine for embedded Gallery2 operation.
Gallery2 locations OK The Gallery2 location settings appear to be correct.
Drupal Modules / Gallery2 Plugins Warning You may have some loss in functionality in your embedded Gallery2 (see below for details). You should check the details and if the functionality is not important for your site you can just ignore this.
Clean URL / URL Rewrite OK There is a writable .htaccess file in your defined Drupal directory (/home/munge/public_html/). Your 'Show Item' rule should start with '/gallery/'. Make sure to change the URL Rewrite rule(s) accordingly.
Initial User Synchronization OK Your initial user synchronization has been completed already.
If you want to resync all your users or you want to import users from an existing Gallery2 setup, you can always use the Advanced Sync options in the Gallery user administration.

I did change the Show Items link in the Gallery2 standalone app, but it doesn't appear to do anything.

My users have a link in their navigation menu titled "Gallery" but it links to http://gallery/ which is quite obviously wrong.

The .htaccess in my Drupal root looks like this:

Quote:
# BEGIN Url Rewrite section
# (Automatically generated. Do not edit this section)
<IfModule mod_rewrite.c>
RewriteEngine On

RewriteBase /

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d [OR]
RewriteCond %{REQUEST_FILENAME} gallery\_remote2\.php
RewriteCond %{REQUEST_URI} !/gallery$
RewriteRule . - [L]

RewriteCond %{THE_REQUEST} /d/([0-9]+)-([0-9]+)/([^/?]+)(\?.|\ .)
RewriteCond %{REQUEST_URI} !/gallery$
RewriteRule . /gallery2/main.php?g2_view=core.DownloadItem&g2_itemId=%1&g2
_serialNumber=%2&g2_fileName=%3 [QSA,L]
RewriteCond %{THE_REQUEST} /gallery/v/([^?]+)(\?.|\ .)
RewriteCond %{REQUEST_URI} !/gallery$
RewriteRule . /gallery?g2_path=%1 [QSA,L]
</IfModule>

# END Url Rewrite section

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php?q=$1 [L,QSA]
</IfModule>

And the .htaccess in my gallery2 directory looks like this:

Quote:
# BEGIN Url Rewrite section
# (Automatically generated. Do not edit this section)
<IfModule mod_rewrite.c>
RewriteEngine On

RewriteBase /gallery2/

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

RewriteCond %{THE_REQUEST} /gallery2/d/([0-9]+)-([0-9]+)/([^/?]+)(\?.|\ .)
RewriteCond %{REQUEST_URI} !/gallery2/main\.php$
RewriteRule . /gallery2/main.php?g2_view=core.DownloadItem&g2_itemId=%1&g2
_serialNumber=%2&g2_fileName=%3 [QSA,L]
RewriteCond %{THE_REQUEST} /gallery2/gallery/v/([^?]+)(\?.|\ .)
RewriteCond %{REQUEST_URI} !/gallery2/main\.php$
RewriteRule . /gallery2/main.php?g2_path=%1 [QSA,L]
</IfModule>

Can someone tell me what is going wrong? I just can't get at Gallery at all from within Drupal and I don't get why. I imagine it's because of the http://gallery/ link which is clearly wrong, but I don't know what it is supposed to be so I can't troubleshoot it.

Any help is appreciated.

Thanks

Jon

Login or register to post comments
jonwatson

Joined: 2009-08-11
Posts: 10
Posted: Wed, 2009-08-12 12:40

Any ideas, anyone? I need to get this thing working and am quite puzzled as what is broken.

Thanks,

Login or register to post comments
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 9282
Posted: Wed, 2009-08-12 20:51

What little I know about integrating Gallery into other apps is just from the very little I've read.

First make sure standalone is working. I believe to get URL Rewrite working though, you need to configure that while going through the integration, not through standalone Gallery.

I've read most of your post and I'm not sure if that will help or not seeing as how you say you can only access Gallery through standalone. But as far as that, I've only used Gallery in standalone or visually integrating it into a site, but not integrating it into another application.
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

Login or register to post comments
jonwatson

Joined: 2009-08-11
Posts: 10
Posted: Thu, 2009-08-13 11:50

Hi,

I managed to get everything working by doing two things:

1. Putting in a full URL (http://www.mysite.com/gallery2) into the URI or URL of gallery2 installation, and
2. Turning off clean URLs in Gallery2.

So it now all works, but I would prefer clean URLS, but can live without.

I have to say, this was one of the more painful module installations I've done on Drupal. It seems that there is still some work to be done with it as there are a few things that don't seem to work as documented.

Thanks,

Jon

Login or register to post comments
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 9282
Posted: Thu, 2009-08-13 12:01

Well, there's not much work that's going to be done with any more integrations or much else related to G2. All new development is focused on G3 and it's planned that integrating with G3 will be easier, though work on that part hasn't started yet.
____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

Login or register to post comments
jonwatson

Joined: 2009-08-11
Posts: 10
Posted: Thu, 2009-08-13 12:53

That's fine. I can wait now that things are working aside from the somewhat trivial clean URLs.

Thanks,

Login or register to post comments
ak10

Joined: 2009-09-09
Posts: 4
Posted: Wed, 2009-09-09 03:40

This looks similar to my URL problem which I chronicled here. Is there a way I can edit the URI or URL of gallery2 after the installation? My host installs it automatically but I can re-do it manually if that is the only way.

Login or register to post comments
nivekiam
nivekiam's picture

Joined: 2002-12-10
Posts: 9282
Posted: Wed, 2009-09-09 04:03

I just replied to you in that thread

____________________________________________
Like Gallery? Like the support? Donate now!!! See G2 live here

Login or register to post comments