Geeklog issues relating to simple URLs

vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Sun, 2004-05-02 17:05

Hi all,

I'm a long time Gallery and Geeklog user, and I've been integrating the two programs together manually in the past. While that has worked fine, it was a bit of a pain, since several files needed to be edited, etc.

So I was quite happy to find that Gallery 1.4.3 has GeekLog integration built in. Awesome!

However, it seems that simple URLs no longer work. :-( In the old days, I could type in http://w3log.vjl.org/gallery/vjl-at-nc and I would be sent to the correct album. Now I just get a 404 error.

I've made sure that I've set rewrite on:

$gallery->app->feature["rewrite"] = 0;

in my gallery config.php, yet, the only way I am able to access my albums is via a URL like this:

http://w3log.vjl.org/gallery/view_album.php?set_albumName=vjl-at-nc

What do I need to do to fix this? It was working with the 'old fashioned' geeklog/gallery integration method.

Thanks for any info y'all might have...

/vjl/

 
h0bbel
h0bbel's picture

Joined: 2002-07-28
Posts: 13451
Posted: Sun, 2004-05-02 20:07

$gallery->app->feature["rewrite"] = 0; disables mod_rewrite use in Gallery. It should be set to $gallery->app->feature["rewrite"] = 1; if you have mod_rewrite installed on your apache setup.

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Sun, 2004-05-02 20:17

h0bbel,

Hmm...that doesn't seem to help. :( I had it on '1' already, and read in the FAQ that it needed to be '0'. Switching it back to '1' hasn't made a difference. mod_rewrite is installed and enabled [it was working prior to my upgrading of GL and Gallery.

I also found out that any user other than myself will not stay logged in when viewing the gallery part of GeekLog. Eg: the user logs in to GL fine, and can navigate within GL. Once they hit the Gallery, though, GL doesn't know who they are, and puts up a login/logout block.

Since neither of these problems appeared before the latest version and new integration, either something is messed up with the GL/Gallery integration, or I messed up the install somehow. There isn't any documention [that i could find] for setting up Gallery within GeekLog, so it's very likely I didn't do something right.

All of the GL integration scripts/documents all reference older versions of Gallery and GL. I wonder if there is some documentation for the current versions of Gallery and GL that I could use.

/vjl/

 
h0bbel
h0bbel's picture

Joined: 2002-07-28
Posts: 13451
Posted: Sun, 2004-05-02 20:20

vjl323, so far all the documentation relating to GeekLog is in the contrib/geeklog folder.

I'll forward this post to the developer who did the integration, he might have more info for you.

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Sun, 2004-05-02 20:26

h0bbel,

Yeah, I spotted that during the install. All it is is a changelog and a credits file. While I don't mean to complain, it isn't exactly what I would call 'documentation' [the changelog only has one entry!].

FWIW, I did have Gallery 1.4.1 [iirc] and GL 1.3.7 working very well together. Simple URLs worked, and user authentication worked, and Gallery honored the GL theme when it was embedded. Granted, the process of integrating it meant having to change several Gallery core files, which I didn't like doing, since with each new version of Gallery, it meant changing those files again, and/or hoping those files *could* still be changed!

If the developer who did the integration needs a test subject or more info, please let me know - I'm willing to try anything to get things working again. :)

Thanks for your help...

/vjl/

 
h0bbel
h0bbel's picture

Joined: 2002-07-28
Posts: 13451
Posted: Sun, 2004-05-02 20:28

vjl323, i agree that the documentation is, well, "sparse" ... :) Anyway, iæve let him know, I guess he'll see it in the morning (european time. :) )

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Sun, 2004-05-02 20:36

h0bbel, Thanks for letting him know. I'm on the west coast of the US, so I'll probably still be around when it's morning over there. :)

BTW, if I can get this up and running, I will gladly write a FAQ/HOWTO/WIKI/whatever to help others who use GL and Gallery together.

/vjl/

 
h0bbel
h0bbel's picture

Joined: 2002-07-28
Posts: 13451
Posted: Sun, 2004-05-02 20:44

vjl323, that would be awesome. The easiest way for you to contribute, is to add it as a note to the documentation, and we'll incoporate it from there.

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Mon, 2004-05-03 17:15

h0bbel, dumb question for you - where do I add the note? Should I just create a fresh text file with the GL integration steps? I can do that as soon as I know just what they are for version 1.4.3 of gallery and 1.3.9 of GL. :) I tend to over-document everything, so I won't have any problem documenting the procedure, once I can get it to work.

Once I do get it working, and docs written, where/whom do I submit the docs too?

Thanks for all the help - hopefully the GL integrator can throw an idea my way soon. :)

/vjl/

 
h0bbel
h0bbel's picture

Joined: 2002-07-28
Posts: 13451
Posted: Mon, 2004-05-03 17:28

vjl323, email it to me at

. I'll integrate it. :)
I'll remind him when he comes online. :)

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Fri, 2004-05-07 17:09

h0bbel, will do - I'll e.mail you any/all text i write about it. I'm going to do a completely new install of GL and Gallery to test it out in and see if I don't have the same problems I still have with my upgraded install [which i still haven't heard anything about].

To summarize, problems I see with GeekLog and Gallery:

simple/short URLs don't work
all users, except the admin, aren't logged in when viewing a gallery page

I do know the Gallery is using GeekLog users, as when I add a new GL user, and go into gallery [as admin], the new user shows up in the permissions window. But users aren't logged in when they view a gallery page.

I'll upgrade my GL/Gallery to the pl1 release today to see if that helps.

/vjl/

 
MrHyde

Joined: 2003-09-08
Posts: 14
Posted: Sun, 2004-07-04 02:41

vjl323: Did you manage to write the documentation on how to integrate Gallery and Geeklog.

Can anyone answer the following questions for me.

I've been using both separately and now what to embed Gallery into Geeklog. The new installation worked fine and gallery is using the geeklog login, but I've got a number of questions outstanding.

1) How do I give permission to other gl users to be able to post pictures. Nowhere do I see a link to Manage Users like in the standalone version. The only links that are visible when I log into gl as admin are Slideshow, Documentation and New album.

2) How do I create a link to the gallery on the front page?

Thanks.
Vivek

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Sun, 2004-07-04 07:14

MrHyde: not yet. Each weekend has been busier than the previous, but I am VERY close to getting stuff setup before this Wednesday. I did find that the new integration [the one that comes with gallery] is VERY limited. The hack that I had in place long ago with an older version of Gallery and Geeklog let me create a "Photo User" geeklog group, and if I assigned a user to that group, they could manage a photo album. It also allowed for short URLs.

I do know that the CVS version of gallery 1.4.4 does have support for short URLs in geeklog. Hopefully it will also allow the ability to give normal, non-admin geeklog users the ability to post photos, as both functions were available well over a year ago using a much more difficult to implement gallery/geeklog hack [it meant having to hand edit several gallery and geeklog files - something that one should only do if one knows what they're doing.

As far as your 2nd question - I just edit the header.thml layout file such that there is a link pointing to your geeklog's installation directory followed by /gallery. In my case, I installed gallery in a directory called, "gallery" inside the main geeklog directory. I also added a link via a special block on the left side of my home page.

You can see this in action at: http://w3log.vjl.org/

The link in the top to "Gallery" was created in my layout/header.thml file and looks something like this:

<a href="{site_url}/gallery">Gallery</a>

Let me know if that helps. I'll keep this thread updated when I have some documentation to finally publish. Hopefully before next weekend is here!

/vjl/

 
MrHyde

Joined: 2003-09-08
Posts: 14
Posted: Tue, 2004-07-06 08:59

Thanks Neil,

It has helped a bit. I've changed the user to a root user so they can create new albums and upload pictures, but would love to use a Gallery User group.

I've also found that the remote doesn't work. Guess I'll have to wait till they implement everything in the next release of Gallery.

Cheers,
MrHyde

 
vjl323
vjl323's picture

Joined: 2002-12-19
Posts: 39
Posted: Tue, 2004-08-03 12:48

Who's Neil? :-)

I finally got around to installing 1.4.4 and it is a LOT smoother than 1.4.3's install, with regard to GeekLog. One thing you need to change in order to give non-GeekLog admins the power to add new albums:

Go into the gallery/classes/geeklog directory and edit User.php. Look for the function:

function loadByUserName($uname) {

and note the text at the bottom of that function:

$this->canCreateAlbums = $this->canCreateAlbums();

Comment that line out by putting a "#" in front of it [w/o the quotes]. Then add this line instead:

$this->canCreateAlbums = 1;

That will allow NON-admin [aka root] users the ability to create new albums and edit/delete albums that they own. It will not allow them to full gallery admin rights [in other words, they can not delete/edit albums they don't own].

The drawback to this is that ALL of your geeklog users will now be able to create albums. In the future, I want to set up gallery/geeklog so that it integrates like it used to, and one can create a geeklog group called, "gallery admin" which would allow users in that group to create their own albums. This is handy for large geeklog installs, where one does not want every geeklog user having the ability to create a new album.

/vjl/ [who is very happy with gallery 1.4.4 and geeklog integration - short URLs work now!]