I just installed Drupal over the weekend and also installed Gallery 2. I've installed the modules for embedding and I've imported my old albums from Gallery 1. When I go into Gallery settings on the install page it's not finding the path no matter how I put it in. Here's the error: Location of Gallery2: file /home/etc/gallery2/embed.php does not exist [Error]
I've tried the manual configuration. I've tried the full URL. The file embed.php is indeed in the gallery2 root.

I'm getting a Gallery2 location error. Then the next two, plug-ins and clean url rewrites both say Warning. And then the last one Initial User Synchronization is another error.

Did I miss something simple because I'm a newbie or what?

Your help would be greatly appreicated.

Sheila

Comments

lvthunder’s picture

Does your g2 work? Also what is the Drupal path and the G2 path?

SheilaHoff’s picture

In reading through this forum I came across this info "To use the D6 version you need Gallery 2.3 which isn't out yet. You can download a nightly snapshot of it though on the gallery page and it will work." SO...I'm confused... how is it that you all are actually able to embed Gallery2 if 2.3 is required and isn't out yet. I must be missing something obvious here. Please forgive my ignorance.

SheilaHoff’s picture

Thanks for the response. Yes G2 works. It's at http://evergreentandemclub.org/gallery2 and drupal is at http://evergreentandemclub.org/drupal

I've been trying /home/etc/gallery2 for the gallery path as that's what my host provided. Perhaps the issue is that Gallery2 in not inside the Drupal folder?

Thanks!
Sheila

lvthunder’s picture

Well if your using D6 you need to download the nightly version of g2. Also you need to move your G2 install inside the drupal root. So say /drupal/gallery2.

SheilaHoff’s picture

Thanks again for helping me. I'm sorry I'm so new to all this that my questions are so basic. What's the best way to approach this now? Can I literally copy the Gallery2 folder over to the Drupal folder? Or should I uninstall and reinstall the whole thing? And then I'll need to re-import the old G1 albums. I've never used the nightly builds. How does that work? Thanks for holding my hand and walking me through these basics.

lvthunder’s picture

Here is a link on how to move the install.

http://codex.gallery2.org/Gallery2:FAQ#How_can_I_move_my_gallery_install...

Well the nightly builds are just like the ordinary builds except that it changes everyday. Most of the time everything works fine, but there is no guarantee. I've never had many problems especially now that G2.3 is getting close to being done.

SheilaHoff’s picture

Thanks. The move went very smoothly. I haven't done a new build install. I'm hoping that'll help as just changing the directory didn't fix the problem.

SheilaHoff’s picture

Do I need to just copy over all the files in the nightly build? And do I need the Drupal nightly build from Gallery as well?

lvthunder’s picture

Yeah just replace all the files in the G2 folder with the files from the nightly build. then run gallery2/upgrade to upgrade the database. You shouldn't have to change anything in Drupal.

SheilaHoff’s picture

YEAH...I successfully updated G2 and was able to complete the Gallery setup in Drupal. I can now see the embedded gallery so this is GREAT progress. However... There may be a simple path correction needed somewhere. I'm not seeing the images which are there when I go directly to the unembedded gallery. This is not the WWW bug as I am seeing red X for each missing photo which doesn't happen with the WWW bug. I suspect it may just be in the config or somewhere else, but again as a newbie I don't want to muck it up. Also, when I try to go to gallery admin or do any admin functions all the links take me back to the parent site. This must be because I have my whole Drupal as a subfolder of the current site and/or because I moved it. I'm hoping there's an easy fix and I don't have to start all over.

unembedded gallery: http://evergreentandemclub.org/drupal/gallery2
embedded gallery: http://evergreentandemclub.org/drupal/gallery

Thanks for continuing to hold my hand. I won't tell my husband! ;-)

Sheila

lvthunder’s picture

You need to give the anonymous user rights to view the gallery in Drupal so I don't get an access denied message.

SheilaHoff’s picture

Try it now. I think I did it correctly.

lvthunder’s picture

Under the gallery settings in Drupal on the Install tab (step 2) what does Gallery2 URL or URI say?

SheilaHoff’s picture

Hmmm....when I click on Install from within the Gallery Settings interface I get a blank page! The path it's looking for there for the install is http://evergreentandemclub.org/drupal/admin/settings/gallery/install
But there is no admin folder within drupal it's within drupal/gallery2 folder.

I downloaded the config.php figuring that has to have the paths you're after. Here's what I found there...

$gallery->setConfig('data.gallery.base', '/home/etc/public_html/drupal/gallery2/g2data/');
$gallery->setConfig('baseUri', 'http://evergreentandemclub.org/drupal/gallery2/main.php');

I hope that's useful. OR...tell me where else to get the info.
Thanks as always.
Sheila

lvthunder’s picture

That's the page you need. If it's a blank page that generally means it ran out of memory. Check the webserver error logs to see if you get a message there. You may need to find out how to increase the php memory limit. I can't tell you how to do that because there are a few different ways to do it depending on how the server is set up.

SheilaHoff’s picture

OK...I'll ask my host about increasing php memory limit. But don't you think it's looking in the wrong place for stuff?

lvthunder’s picture

Yes I do, but the settings I think you need to change are on that page. These are drupal settings not G2 settings that are messed up.

SheilaHoff’s picture

Here's what the error log says:
[Tue Jun 17 18:50:53 2008] [error] [client 116.206.54.71] File does not exist: /home/etc/public_html/gallery2, referer: http://evergreentandemclub.org/drupal/gallery

lvthunder’s picture

Once you can get that page to load you can change the settings so it points to the correct place.

SheilaHoff’s picture

OK. I've asked my host but it may take awhile to get the extra memory. I hope that fixes it so we can get into the install page. Meanwhile the other path in the config.php is:
$gallery->setConfig('data.gallery.base', '/home/etc/public_html/drupal/gallery2/g2data/');
and that's correct as well for the data. Yet the data's not displaying.

Sorry...I'll try to be patient. I'm so grateful you're helping me. Thank you!

lvthunder’s picture

Everything in config.php is for the standalone version too. So if the standalone version works don't change anything there.

SheilaHoff’s picture

AH...that makes sense! Thanks. So what if increasing the memory doesn't help? Isn't there any other way at this?

SheilaHoff’s picture

OK, they responded and told me to put this into the .htaccess file: php_value memory_limit 16M which I did. And sadly... NO JOY! Now what?

lvthunder’s picture

Which .htaccess file did you put it in. Also I would make it 32 instead of 16.

SheilaHoff’s picture

the .htaccess file in the root. Where should it go? I'll adjust the amount.

SheilaHoff’s picture

Oh boy...I just F**Ked up! My impatience got me. I stupidly copied the .htaccess I'd downloaded from the root and added the memory limit to and uploaded it to the drupal directory since it hadn't helped in the root directory! Ooops. I didn't check to see what was in the drupal directory's .htaccess. Now my link to the gallery embedded in Drupal no longer takes me to the broken version it pushes me back to the root of the site! I've totally screwed this up. Is there any help for me now?

SheilaHoff’s picture

I can't find a search function on the Drupal site except in the forums and it won't let me access that. The aforementioned screw up has left my site entirely unuseable. No links work now. As far as I can tell the thing that did it is overwriting the drupal root .htaccess file. I want to try to figure out how to rewrite it, what was in it? That's why I was looking for a search function. Please tell me what to do besides kick my butt and hang my head in shame for making such a stupid mistake. Thanks.

SheilaHoff’s picture

OK...I downloaded a fresh copy of Drupal and copied over the .htaccess file, unedited back to my drupal folder and I can now access my entire site again. I still have the issues with the gallery. Now I can focus on them again.

lvthunder’s picture

So did you add the memory limit to the .htaccess file? Did it give you access to the settings page?

SheilaHoff’s picture

I added php_value memory_limit 32M to the end of the fresh .htaccess in the drupal folder and still NO JOY. Is there any particular place or format I need to know to add it? Do I also need to do something with the php.ini file?

SheilaHoff’s picture

I'm busily reading documents on the white-page-of-death and increasing memory in .htaccess and php.ini. I've been adding memory to .htaccess in the drupal directory but just read that maybe I'm supposed to be doing it in the G2 directory. I've tried both, up to 512M and still NO JOY! I'm going to need to give this a rest for the night but I'm hoping to resolve this with a fresh day tomorrow. Thanks again for all your help. I can't tell you how much it means to me that you've stayed with me through this. thank you!

lvthunder’s picture

Keep it at 64MB. That's what mine is set up as. You either need to add the memory line to .htaccess or a php.ini file. It all depends on how the server is set up. To tell if it is working under Administer in the logs section there should be a status link. Click that then click PHP. I hope it's like that in Drupal 6. I'm still using Drupal 5.

SheilaHoff’s picture

Good morning. I got the 512M from a post where someone said they kept upping it until it worked and he needed that much! Here's that link: http://drupal.org/node/29268. I just checked my Status Reports and for php Memory it's BLANK! The only things that have a yellow caution instead of green check are Chron jobs and Core Update Status. I noticed we're running PHP 4.4.8. Could that be an issue? I have 5 available. The old site running on PostNuke needs 4 though so if Druapl wants 5 I'll need to setup another account to host it. Should've done that to start with! Will I be able to port this whole thing over to a new location easily or will it be a complete reinstall and setup?

So why is the ph Memory showing as blank? Is there a special format to use? Just to confirm this .htaccess file is the one in the Drupal folder.

lvthunder’s picture

The htaccess should look like this

php_value memory_limit 32M

As for that value being blank I don't know.

SheilaHoff’s picture

I just opened the Drupal .htaccess and added php_value memory_limit 32M, saved and refreshed and still seeing the white-screen-of-death.

BTW...one thing that changed when I messed up and had to replace the Drupal .htaccess. Now my embedded gallery no longer shows red X for missing images. It shows the text but nothing else. And it's still sending all links within the gallery to the root site instead of within the embedded gallery.

Should I try a new nightly build?
Should I try posting for help at the main Drupal forum instead of in this Gallery2 forum?

I've so appreciated your help but it seems we may've come to a dead end unless you have some other ideas for me to try.

Thanks so much.
Sheila in Seattle

SheilaHoff’s picture

I just ran a gallery report and found this
gallery_embed_uri: /index.php?q=gallery
gallery_dir: ./gallery2/
That's just wrong. That's where it's being told to go the the root.
And the referer is http://evergreentandemclub.org/drupal/admin/settings/gallery
there is no admin/settings/gallery within my drupal folder. Should there be?

The links on the embedded gallery say things like:
http://evergreentandemclub.org/index.php?q=gallery&g2_itemId=36
When I edit that and add the correct path to drupal/gallery/ it then brings up the correct page. Still no images however.
http://evergreentandemclub.org/drupal/gallery/main.php?q=gallery&g2_item...

Should I try downloading last night's build and reinstalling over this?

lvthunder’s picture

Yeah that second one is the one you need to change.

There's not a drupal/admin/settings/gallery folder. The .htaccess file converts paths like that to something that drupal understands. If you want to see the true path turn off clean URL's in Drupal.

SheilaHoff’s picture

OK, I turned off clean URLs. I don't see that my report gives anything different however. You haven't answered my question about what I should do next. I realize you think the memory is the issue because of the white screen. However, we haven't been able to fix it that way. So I ask again, should I try reinstalling Drupal or G2 or both over the current install? Will I lose everything if I do that? Or should I start clean with a fresh account? If so, what are the best practices for then getting the work I've done over there?

Thank you.
Sheila

SheilaHoff’s picture

When I try to access the install page from within Drupal it goes to:
http://evergreentandemclub.org/drupal/?q=admin/settings/gallery/install
I just played around with the url for the installer. I can access the G2 installer at:
http://www.evergreentandemclub.org/drupal/gallery2/install/

Will running that installer allow me to fix it? You did say that if G2 is working when not embedded to leave it alone. I'm guessing that's the case with this question...that this will muck with the stuff that's already working. But can I get any info you need via this route?

lvthunder’s picture

No G2 is not the one that is broken. It's the settings for the integration module that is. Maybe if you uninstall the G2 module from Drupal (not G2 itself) and reinstall you might be able to fix it.

SheilaHoff’s picture

sounds like a plan. Do I just delete the Gallery folder in Modules or is there an uninstall somewhere?

lvthunder’s picture

Uncheck the gallery module under modules. Then you can delete the folder. I'm not sure if there is an uninstall other then that.

SheilaHoff’s picture

That didn't help either! I unchecked all the G2 items, and saved configuration. Then I deleted the gallery module folder and uploaded a new one. It did exactly the same thing...no photos and all links are with wrong path and I still get the white screen.

I'm seriously thinking about giving up!

lvthunder’s picture

Well I don't know then. I would ask your host why in phpinfo the memory setting is blank.

aqswdefr’s picture

Check the permissions on your G2 folder. They should be 755.

SheilaHoff’s picture

Thanks, the folder IS set to 755. I will ask my host about the phpinfo memory being blank though.

SheilaHoff’s picture

Here are the results of my ticket with my host....

Currently the memory_limit on the server is set to 32M, do you require this to be set higher? Also, here is the error messsage that is generated in the apache error logs when clicking install:

[Thu Jun 19 21:49:38 2008] [error] [client 72.12.208.4] File does not exist: /home/etc/public_html/gallery2, referer: http://evergreentandemclub.org/drupal/admin/settings/gallery

And after turning off Clean URLs I asked them to try again and got this...

It appears that the memory_limit is set to 64M. And your site is still generating the same error message in the Apache logs. However, this error doesn't actually show when clicking install. It does, however, show whenever navigating to any of your pages.

I suggest checking the Drupal forums for ideas on what could be causing this.

edgibson’s picture

Just in case this may help anyone... TRY USING FIREFOX 3!!

I fought and fought with the above issues:

- Trouble setting path
- Pictures not showing

This was occuring on several sites that I had "cloned" from a working install (Drupal 6.2 & G2.x "nightly build").

What finally worked for me was this:

- uninstalled the Gallery module (drupal) and reinstalled it. Use the "uninstall tab" in drupal modules admin.
- went to the install option for the Gallery module (Drupal admin) and with Firefox 3, I set the URL/URI (manual option) to: http://www.mydomain.com/gallery2/ and I set the path to: gallery2/

This cleared the location errors and I just proceeded through the next steps without changing the default settings.

This worked on each of the sites and on the first couple I tried both IE and Firefox, sometimes it works with one, sometimes the other.

BTW - THANK YOU for helping me resolve this - your post about "red x's" was the clue to trying Firefox (since it doesn't show red x's for broken images, I figured you were using IE)