Loading...
 
Skip to main content

Viewing an image after sorting by file size throws an error.

Status
Closed
Subject
Viewing an image after sorting by file size throws an error.
Version
1.9.x
2.x
Category
  • Error
  • Dogfood on a *.tiki.org site
Feature
Image Gallery
Resolution status
Fixed or Solved
Submitted by
Marc Laporte
Volunteered to solve
luci
Lastmod by
luci
Rating
(0)
Description

To reproduce, visit:
http://themes.tikiwiki.org/tiki-browse_gallery.php?galleryId=1Question

And sort by file size:
http://themes.tikiwiki.org/tiki-browse_gallery.php?galleryId=1&offset=0&sort_mode=filesize_descQuestion

Then, click an image:
http://themes.tikiwiki.org/tiki-browse_image.php?galleryId=1&sort_mode=filesize_desc&imageId=17&scalesize=oQuestion


You will get:

Image
Copy to clipboard
Warning: mysql error: Unknown column 'filesize' in 'order clause' in query: select `imageId` from `tiki_images` where `galleryId`=? order by `filesize` desc in lib/tikidblib.php on line 134


Also see:
http://dev.tikiwiki.org/tiki-view_tracker_item.php?itemId=1345Question

Solution

Fixed on 1.10 CVS/SVN in lib/imagegals/imagegallib.php

FIX if sort by filesize is set while browsing images it needs to be read from tiki_image_data table + corrected prev/next image browsing bug1345 bug1399 — luci

Fixed for 1.9.x too

Importance
5
Priority
25
Demonstrate Bug on Tiki 19+
Demonstrate Bug (older Tiki versions)
Ticket ID
1399
Created
Monday 12 November, 2007 22:08:00 UTC
by Unknown
LastModif
Thursday 24 April, 2008 21:15:38 UTC


Show PHP error messages