Next and Previous in keyword albums causing problems with linked items with keywords

rutteger

Joined: 2013-05-14
Posts: 2
Posted: Wed, 2013-05-15 08:59

Slight issue I've noted on the keyword albums I've been unable to resolve or workaround. Done a load of searching and not seen it mentioned.

Probably easiest to take a look directly. Go to this keyword album > http://www.retrobike.co.uk/gallery2/key/MTB. Click on linx (top row #4). Click previous and you will see you get a 500 error. If you go back to the keyword album view and click the previous item it shows fine.

Basically looks like that for any linked items tagged with keywords when you attempt to naviagte to these using the next or previous buttons the link is not generated correctly and a 500 error is shown.

Any ideas / suggestion or workarounds. Guessing it maybe related to the URL rewrite but not wanting to disable this.

Is it possible to simply omit next / previous navigation in keyword item display only?


Gallery URL = http://www.retrobike.co.uk/gallery2/main.php
Gallery version = 2.3.2 core 1.3.0.2
API = Core 7.54, Module 3.9, Theme 2.6, Embed 1.5
PHP version = 5.2.17 apache2handler
Webserver = Apache/2.2.3 (CentOS)
Database = mysqli 5.5.30-cll, lock.system=flock
Toolkits = ArchiveUpload, ImageMagick, Gd, LinkItemToolkit, Thumbnail
Acceleration = none/1814400, none/432000
Operating system = Linux 2.6.18-194.26.1.el5 #1 SMP Tue Nov 9 12:54:20 EST 2010 x86_64
Default theme = matrix

 
suprsidr
suprsidr's picture

Joined: 2005-04-17
Posts: 8339
Posted: Wed, 2013-05-15 11:37

Notice that clicking on a LinkItem directly from within your KeyAlbum it takes you out of the KeyAlbum directly to the LinkItem in its normal album whereas clicking a normal item keeps you in the KeyAlbum.

I think gallery only knows one way to generate links for LinkItems.

-s
________________________________
All New jQuery Minislideshow for G2/G3

 
rutteger

Joined: 2013-05-14
Posts: 2
Posted: Wed, 2013-05-15 13:10
suprsidr wrote:
Notice that clicking on a LinkItem directly from within your KeyAlbum it takes you out of the KeyAlbum directly to the LinkItem in its normal album whereas clicking a normal item keeps you in the KeyAlbum.

I think gallery only knows one way to generate links for LinkItems.

-s
________________________________
All New jQuery Minislideshow for G2/G3

That seems about right. However when you try and use next / previous from within an item in the keyword album to reach a link item the URL gallery tries to use is along the lines of

http://www.retrobike.co.uk/gallery2/key/MTB?g2_itemId=39255

Which fails. However

http://www.retrobike.co.uk/gallery2/main.php?g2_itemId=39255

works ok.

 
Dayo

Joined: 2005-11-04
Posts: 1642
Posted: Sun, 2013-05-19 05:13

I'll expect that the module should generate valid links but can't check right now.

You can use a htaccess rewrite to redirect the offending links by adding something along the lines below to your htaccess file. Probably better to add near the top of any G2 auto generated rules.

RewriteRule ^\gallery2/key(.+)g2_itemId=(.+)$ /gallery2/main.php?g2_itemId=$2 [R=301,NC,L]

--
dakanji.com