Does anyone actually have a working D6 / G2.3svn / G2 embedded setup ?

Jeremy Toaster

Joined: 2008-03-05
Posts: 14
Posted: Mon, 2008-03-10 02:13

I was curious if anyone actually had a full working embedded Gallery 2.3svn / Drupal 6 site?
There seem to have been a lot of updates to both the stand alone and embedded versions lately, and after seeing many many posts with people having issues with the Gallery URL Rewrites and embedding it into Drupal, I was wondering if anyone had successfully accomplished an integration yet, and if so, could they post their steps and .htaccess files for us to all compare with our own. Cause I believe the problem lies within those 2 files and there is some sort of conflict between the two.

Thanks ahead of time!

jeremy
(p.s. yes I have fully read and re-read and re-read many times all the installs and posts and updates and everything else...)

 
mike2854

Joined: 2008-03-26
Posts: 1
Posted: Wed, 2008-03-26 11:10

I have tried install D6.1 + G2.3svn + G2,
my case is install in UserDir, please adjust the path for your needs
hope my install steps are what you need.

1. Install D6 under ~/public_html, DO NOT enable 'Clean URL' at this moment.

2. Install G2.3svn under ~/public_html

3. Create symbolic link in D6 directory to G2 directory, let D6 to access embedded G2
(in drupal directory : ln -s ../gallery2 .)

4. access G2.3svn under D6 directory (http://domain/drupal-6.1/gallery2), config G2.3 plugins:
i. Disable Registration
ii. Config and Enable URL Rewrite with apache setting
==> At this point, G2 under drupal directory has 'Clean URL'

5. Install D6 gallery module,
Before Installation, please chmod .htaccess in drupal dir to 666
A. there are 4 fields in location setting
i. G2 URI : /~user_name/drupal-6.1/gallery2/
ii. G2 fs path: /home/user_name/public_html/drupal-6.1/gallery2/
fs path should give absolute path, to ease the g2image installation
iii. embedded URI: /~user_name/drupal-6.1/index.php?q=gallery
usually the default one is correct already.
iv. Gallery base: gallery
just default value
B. URL rewrite
Usually the default value is ok, in my case
Public path to your .htaccess file: /~user_name/drupal-6.1/
Filesystem path to your .htaccess file: /home/user_name/public_html/drupal-6.1/
C. User Sync
Do as normal.

6. Enable D6 Clean URL
If system do not allow you enable it:
go to .htaccess under D6 Directory
change "RewriteBase /" to "RewriteBase /~user_name/drupal-6.1/"
Enable Clean URL and everything goes fine.
Finally please chmod to protect your .htaccess under D6 directory.

 
Jeremy Toaster

Joined: 2008-03-05
Posts: 14
Posted: Wed, 2008-03-26 13:18

Hey thanks a lot for the very detailed install. I plan to try this out tonight and see how it goes. I will report back my findings!

Thanks again.

jeremy

 
Jeremy Toaster

Joined: 2008-03-05
Posts: 14
Posted: Thu, 2008-03-27 16:13

Well I went through all of it, and so far so good. One thing I had to do though was SKIP the URL rewrite in the embedding Gallery set up. Then go into the embedded Gallery set up and set the paths in there in the URL rewrite, because I wasn't being give the options during the embedded installation.

Now, the gallery seems to be embedded for the most part, but DRUPAL is not allowing me CLEAN URLs even those I changed the .htaccess file to point to the site. Still telling me "disabled". I know mod_rewrite is working properly cause Gallery let me install it on the stand alone just fine.

Messing around with it more to figure out...

 
sarne

Joined: 2008-04-11
Posts: 3
Posted: Fri, 2008-04-11 00:20

Yes, my D6, G2.3, G2 is all working nicely, except I can't get the g2image icon to show up even though it says it's installed properly.

 
sarne

Joined: 2008-04-11
Posts: 3
Posted: Fri, 2008-04-11 00:24

I just took a quick look, doesn't look like my URL rewrite is working either.

 
Jeremy Toaster

Joined: 2008-03-05
Posts: 14
Posted: Sat, 2008-05-03 15:56

Ok I have pretty much everything working now. The .htaccess has a lot to do with it. After getting that sorted out, I am able to click on images and they show up like they should, BUT, they redirect to a page that removes all Drupal menus from the top and side of the page. I have a feeling this is still a re-direct path issue.

Here are my TWO .htaccess files. One is the Drupal file that is in the Drupal root dir. The second is the Gallery2 file that is in /gallery2/ root dir.

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

    RewriteBase /Library/WebServer/Documents/mysite/www/

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d [OR]
    RewriteCond %{REQUEST_FILENAME} gallery\_remote2\.php
    RewriteCond %{REQUEST_URI} !/Library/WebServer/Documents/mysite/www/index\.php$
    RewriteRule .   -   [L]

    RewriteCond %{THE_REQUEST} /Library/WebServer/Documents/mysite/www/v/([^?]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/Library/WebServer/Documents/mysite/www/index\.php$
    RewriteRule .   /gallery2/main.php?g2_view=core.DownloadItem&g2_itemId=%1&g2_serialNumber=%2&g2_fileName=%3   [QSA,L]
    RewriteCond %{THE_REQUEST} /v/([^?]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/index\.php$
    RewriteRule .   /index.php?q=gallery&g2_path=%1   [QSA,L]
</IfModule>

# END Url Rewrite section

#
# Apache/PHP/Drupal settings:
#

# Protect files and directories from prying eyes.
<FilesMatch "\.(engine|inc|info|install|module|profile|po|sh|.*sql|theme|tpl(\.php)?|xtmpl)$|^(code-style\.pl|Entries.*|Repository|Root|Tag|Template)$">
  Order allow,deny
</FilesMatch>

# Don't show directory listings for URLs which map to a directory.
Options -Indexes

# Follow symbolic links in this directory.
Options +FollowSymLinks

# Customized error messages.
ErrorDocument 404 /index.php

# Set the default handler.
DirectoryIndex index.php

# Override PHP settings. More in sites/default/settings.php
# but the following cannot be changed at runtime.

# PHP 4, Apache 1.
<IfModule mod_php4.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

# PHP 4, Apache 2.
<IfModule sapi_apache2.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

# Requires mod_expires to be enabled.
<IfModule mod_expires.c>
  # Enable expirations.
  ExpiresActive On

  # Cache all files for 2 weeks after access (A).
  ExpiresDefault A1209600

  # Do not cache dynamically generated pages.
  ExpiresByType text/html A1
</IfModule>

# Various rewrite rules.
<IfModule mod_rewrite.c>
  RewriteEngine On

  # If your site can be accessed both with and without the 'www.' prefix, you
  # can use one of the following settings to redirect users to your preferred
  # URL, either WITH or WITHOUT the 'www.' prefix. Choose ONLY one option:
  #
  # To redirect all users to access the site WITH the 'www.' prefix,
  # (http://example.com/... will be redirected to http://www.example.com/...)
  # adapt and uncomment the following:
  # RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
  # RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]
  #
  # To redirect all users to access the site WITHOUT the 'www.' prefix,
  # (http://www.example.com/... will be redirected to http://example.com/...)
  # uncomment and adapt the following:
  # RewriteCond %{HTTP_HOST} ^www\.example\.com$ [NC]
  # RewriteRule ^(.*)$ http://example.com/$1 [L,R=301]

  # Modify the RewriteBase if you are using Drupal in a subdirectory or in a
  # VirtualDocumentRoot and the rewrite rules are not working properly.
  # For example if your site is at http://example.com/drupal uncomment and
  # modify the following line:
  # RewriteBase /drupal
  #
  # If your site is running in a VirtualDocumentRoot at http://example.com/,
  # uncomment the following line:
  RewriteBase /Library/WebServer/Documents/mysite/www/

  # Rewrite URLs of the form 'index.php?q=x'.
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ /index.php?q=$1 [L,QSA]
 # RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
</IfModule>

# $Id: .htaccess,v 1.90 2007/10/05 14:43:23 dries Exp $

Then here is my Gallery2 .htaccess file

# 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/v/([^?]+)(\?.|\ .)
    RewriteCond %{REQUEST_URI} !/gallery2/main\.php$
    RewriteRule .   /gallery2/main.php?g2_path=%1   [QSA,L]
</IfModule>

# END Url Rewrite section
 
Triptoph
Triptoph's picture

Joined: 2008-06-08
Posts: 6
Posted: Sun, 2008-06-08 18:34

deleted: wrong forum!

 
koyauni
koyauni's picture

Joined: 2008-02-22
Posts: 14
Posted: Sun, 2008-06-15 16:18

I have go it work in D6.2 but I have problem to get the full size image open in new window as it mess up my Theme

http://kurdistanica.com/?q=gallery&g2_itemId=57

I think the G2 dev team has done great job and I can not figure out how they have missed such a basic function. Sometimes the full version is a 1200x1400 for maps, and detailed images. I hope that they will consider to add this feature to the setting for full size image display.

 
pauljr8

Joined: 2008-07-10
Posts: 4
Posted: Fri, 2008-07-11 21:46

No doubt a lot of work has gone into integrating g2 with drupal, but after 2 days of adjusting this chmoding this, resetting that, .htaccess rendering some site parts unfindable, moving files etc. I give up. I will revisit g2 another time. It's been 2 days of solving problems that didn't exist prior to the installation, mostly just making sure that the main drupal site wasn't destroyed just to get another module implemented. It's a great idea and I hope the work will continue, but right now it's a too involved, instructions are confusing and I already have a job.

 
koyauni
koyauni's picture

Joined: 2008-02-22
Posts: 14
Posted: Sat, 2008-07-19 12:05

My Drupal 6.3 works great with G2.3 RC1 but I am getting crazy with the full size image opens in my Drupal them and mess up every thing. The G2 team has not solved this problem even in G2.3 RC1. It should be a simple tick-box to select whether the full version should be open in the same page or new window. This has stopped me to full use G2 as many or my record are full size maps.

Then the case that you can say if the image is taken prior to 1970. This is very annoying and it is still a problem in latest RC1.

 
lvthunder

Joined: 2003-09-12
Posts: 808
Posted: Fri, 2008-08-01 23:45
Jeremy Toaster wrote:
Ok I have pretty much everything working now. The .htaccess has a lot to do with it. After getting that sorted out, I am able to click on images and they show up like they should, BUT, they redirect to a page that removes all Drupal menus from the top and side of the page. I have a feeling this is still a re-direct path issue.

Here are my TWO .htaccess files. One is the Drupal file that is in the Drupal root dir. The second is the Gallery2 file that is in /gallery2/ root dir.

Do you have Gallery Menu Module enabled? There appears to be a bug in that module that is causing the blocks, main, and secondary links not to appear.

I also have a multisite D6 G2.3 install going.
http://photo.lvthunder.com
http://cabin.lvthunder.com

 
DruupyDog

Joined: 2008-12-11
Posts: 1
Posted: Thu, 2008-12-11 13:15

I just installed Gallery2 [6.x-1.x-dev] on Drupal 6.6

The one problem I am having is the same as described above:

Quote:
Ok I have pretty much everything working now. The .htaccess has a lot to do with it. After getting that sorted out, I am able to click on images and they show up like they should, BUT, they redirect to a page that removes all Drupal menus from the top and side of the page. I have a feeling this is still a re-direct path issue

http://dev.craigshoemaker.com/gallery - the G2 main page, displays the menus

But when you click on an Album to view, the top navigation and sidebar menus do not display on the page ...

http://dev.craigshoemaker.com/index.php?q=gallery&g2_itemId=18

Does anyone have a solution for this? I am new to Drupal so I may be missing something obvious!

 
mascot

Joined: 2009-01-31
Posts: 6
Posted: Sat, 2009-01-31 14:25

I have Drupal 6.6 and installed Gallery2. After trying to implemnt gallery2 into my site all my site pages go to 404. Nothing works, I can't even log in to admin panel in my drupal site. Gallery2 is still working fine as a standalone.

Any ideas anyone?

 
lvthunder

Joined: 2003-09-12
Posts: 808
Posted: Mon, 2009-02-02 15:23

Well move G2 into a new folder. That will cause the Drupal module to not find it and it should restore your Drupal site. I would then turn off clean URL's and move G2 back and see if that works.