Gallery 1.5.8

Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Wed, 2008-07-16 11:07

This topic is a for users who have installed Gallery 1.5.8 and have specific bugs to report.
General troubleshooting questions do NOT go in this thread, and will be moved or deleted without asking or warning.

Fixed Version are available via SVN or separately from Jens' archive.
Gallery 1.5.8 is very buggy! We will release 1.5.9 soon, but we have to sort out some things. Please upgrade to at least 1.5.9-svn-b20 in the meantime!

Once reported bugs have been acknowledged and fixed, the bug will be noted here, and responses will be deleted to keep the thread readable.

The known list of bugs in 1.5.8, and their statuses:

Fixed:

1.5.8-pl1-svn-b1:
- Ecard feature is broken. Just shows an empty page with a header.

1.5.8-pl1-svn-b2:
- JS strengthmeter does not work and not available in setup for admin pw.

1.5.8-pl1-svn-b4:
- Link to new password page in 'Self Register' and 'Lost Password' gives "Invalid request"

1.5.8-pl1-svn-b5:
- Icons for slideshow and register on mainpage missing.

1.5.8-pl1-svn-b6:
- Some album actions (e.g. poll results, poll reset) do not appear in the selectbox for album actions.
- Voting for images does not work.
- %d votes instead of number in poll result page.

1.5.8-pl1-svn-b7
- Avoid a single entry selectbox in album view. Do it like in 1.5.7.

1.5.8-pl1-svn-b8
- Delete images found in "validate albums" did not work.

1.5.8-pl1-svn-b9
- Current settings of locale_alias were not selected and thus could overwritten by a different value.

1.5.8-pl1-svn-b11
- Deleting comments within "comments view" did not work.
- Colorpicker did not work when Gallery was embedded.
- Do not show duplicate icons in photoview.

1.5.8-pl1-svn-b12
- Copying a photo from a subalbum into the same album did not work.
- Wrong error message when try to move an item into its current place.

1.5.8-pl1-svn-b13
* ImageMap fixes
- No new ImageMaps at all :-(
- Choosing brush color broken.
- Several ways to hangup JS.

- Zip Icon in thumbs view missing.

1.5.9-svn-b1
- Statistics and its wizard not working correct when embedded.
- Removing invalid albums did not work.

1.5.9-svn-b2
- Stats-Wizard did not work (EVER!) in IE6.

1.5.9-svn-b7/10
- $gallery->app->comments_overview_for_all = "no";
Works now again as supposed.

1.5.9-svn-b8
- Password strengthmeter in setup broke change or set of new admin password.
- FitToWindow broken.
- Config wizard has problems with 0 values

1.5.9-svn-b12
!!! unhtmlentities() changed 0 values to '', that broke sanitizeInput() and thus getRequestVar() !!!

I am very angry about my self,
as this caused a lot trouble at various places.

1.5.9-svn-b13
- Link to comments overview on mainpage.
- getCaptionDate when using exiftags. Use "Image Generated" first, then "Image Created".

1.5.9-svn-b18
Imagemap
- Position of Image were got wrong in IE with horizontal scrolling.
- Init of canvas was done to early, broke display of maps in IE.

Thanks to "Spack" from this forum.

1.5.9-svn-b19
- Moving a subalbum to toplevel broken.

Thanks to Piploff from this forum.

1.5.9-svn-b20
- Move and reorder for main albums were gone ?!?
- Typo in stats.header

Thanks to Piploff from forum for reporting these bugs.

Investigation in progress:

- Not getting to/past step4 of the configuration wizard while upgrading 1.5.7 --> 1.5.8
Reference 1

Rejected:

 
AndrewVasilyev

Joined: 2005-03-24
Posts: 20
Posted: Tue, 2008-08-12 15:10

Any chance to revert to the simple link-style reference for "Photo properties" control
in the album viewer? What was the reason to do <select> element for a single choice?

 
AndrewVasilyev

Joined: 2005-03-24
Posts: 20
Posted: Wed, 2008-08-13 11:55

Many thanks again! :-)

YAST (Yet another strange thing): during the upgrade procedure
(1.5.8b50 -> 1.5.8-pl1-b7) the setup.php rewrites config.php and
changes several locale_alias vars randomly (e.g., I had
locale_alias['ru_RU.koi8r'] = "ru_RU.KOI8-R"
it became
locale_alias['ru_RU.koi8r'] = "en_AU.ISO8859-15"
or something similar). (Looks like one of the system locales, and thanks that not ja_JP.* one.)

Not a problem for an advanced user, but can confuse a blonde. :((

 
jifl

Joined: 2003-07-06
Posts: 18
Posted: Thu, 2008-08-14 03:00

Upgrading to 1.5.8 I've found three issues:

1) $gallery->app->comments_overview_for_all = "no" seems to have no effect. It is described as this:
"Do you want to allow every user who is allowed to view comments (set in permission) to see a complete overview of all comments of an Album? Set this to "no"; if only admin and owners can use this feature."
However any gallery user can get a comments overview, although fortunately they still don't get to see the comments unless the album indicates they have permission to view the comment.

2) The PNG files used by the 'shadows' frame style do not render on my browser, although they worked in the past. My firefox just treats them as fully transparent, i.e. no shadow effect at all. It looks like this actually broke between 1.5.3 and 1.5.4. Reverting to the PNG files of 1.5.3 fixed it. The differences seem to be with nulls and carriage returns, so I wonder if the files simply got corrupted. If they did they may not be alone.

3) It appears that only the album owner or admin can view the photo properties (i.e. EXIF data) now. When admin is logged in, I can see the photo properties icon and click on it. When I log out, the icon for photo properties disappears. For the avoidance of doubt the "Display EXIF data" album property is enabled (and if disabled, the photo properties icon disappears entirely even for admin).

Thanks for looking at this, and all the work on gallery for that matter :-)

Jifl

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Thu, 2008-08-14 10:27

Hello Jifl,

thanks for the feedback.

1.) Can you give me an admin account in your Gallery, so i can have a look?

2.) DARN, i wonder why this happened again. Will fix it (again :-()

3.) From which view are you speaking? Album/thumbs view, or single photo view?

Jens
--
Last Gallery v1 Developer.
Tryout the TEST-Version of Gallery 1.6

 
jifl

Joined: 2003-07-06
Posts: 18
Posted: Fri, 2008-08-15 03:54

Thanks for the reply Jens.

1) Sorry I can't really give out admin. But I'm, shall we say, a sufficiently proficient geek, so just tell me what you want to know about and I can find out. I'm just not familiar with where things are in the gallery codebase specifically. The gallery is here: http://gallery.jifvik.org:9999/gallery/albums.php and to prove the point:
# grep overview_for_all config.php
$gallery->app->comments_overview_for_all = "no";

you can see it happening just by clicking on the 2008 album. There is a "View comments" icon at the top-right and with the description of that option, I would not expect that to be there. And clicking on it does indeed allow you to see comments.
Indeed, the only reference to the comments_overview_for_all option in the whole of my gallery sources is in view_comments.php:

// Further hack check
if (!$gallery->user->canViewComments($gallery->album) &&
        (! isset($gallery->app->comments_overview_for_all) || $gallery->app->comments_overview_for_all != "yes"))
{
        printPopupStart(gTranslate('core', "View Comments"));
        showInvalidReqMesg();
        exit;
}

The only time the option is referenced is if the user isn't allowed to view the comments in the first place. So I'm not even sure the described functionality is really implemented.

2) Ah, I hadn't noticed that an intervening release worked - I haven't always upgraded (unless there was a security fix) so missed some. I would speculate it might be something to do with Windows and line-endings and whatever source code control system you use, although not everything fits for that.

3) Sorry, yes, single photo view. The album view does have a drop down to see the properties, and that works. But the icon is not displayed looking at a single image. The relevant snippet in view_photo.php for deciding whether to show the icon is:

    if ($gallery->album->fields["use_exif"] == "yes" &&
                (eregi("jpe?g\$", $photo->image->type)) &&
                (isset($gallery->app->use_exif) || isset($gallery->app->exiftags)) &&
                sizeof($albumItemOptions) == 2)
        {

From some probing, in fact sizeof($albumItemOptions) is 1. This is because getItemActions is called with its $caption argument left at its default of false. The getItemActions in view_album.php by contrast explicitly sets it to true, causing '<< Photo actions >>' or whatever to be returned in addition to 'Photo Properties'. Anyway, the fix is just to compare against 1 in the above test.

Although this exposes a little visual problem when displaying brackets when $gallery->app->useIcons is set to 'both', as you'll see if you look at the icon text when viewing a photo after the fix. view_photo.php calls getIconText and popup_link. In that case getIconText in content.php puts a <br> at the start. Then popup_link gets called with addBrackets implicitly true, and thus puts square brackets around the icon text, which by now includes the <br>, and so doesn't look right at all. I've worked around this in my gallery by setting addBrackets false.

I suspect that view_album.php is in fact not meant to show the photo properties option in a drop-down though. It seems that the test:

    if (sizeof($albumItemOptions) > 2 ||
         (sizeof($albumItemOptions) == 2 && !isset($albumItemOptions['showExif'])))

is meant to specifically prevent the case where the only option is the photo properties. However for me, that above isset returns false, even though it appears to be one of the arrays. I don't know why: my lack of PHP experience shows here.

Anyway, sorry for the length and hope this helps!

Jifl

 
fundelbot

Joined: 2008-08-15
Posts: 1
Posted: Fri, 2008-08-15 07:52

Upgraded from 1.0 was a breeze and worked great! :)

Encountered a minor problem:
Apache version: Apache/2.2.3 (CentOS)
PHP version: 5.2.6
Operating system: CentOS 5
Web browser/version (if applicable): IE 6/7

Had a javascript error in IE6/7 after the upgrade when logged into admin and attempted to select any of the options in the album actions menu (view_ablum). This gallery has disabled the slideshow option. The javascript error was:

Quote:
Object doesn't support this property or method

Tracked it down to the jopen.js script and found that declaring the the selected var fixed it up:

Quote:
function jopen(element) {
var selected;
selected = element.selectedIndex;

Cheers

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Fri, 2008-08-15 22:09

Your issue is already fixed (b7). You can download the fixes from my archive.

For your upload problem, please enable debug mode, upload a photo via form method and post the output here.
I doubt that its a specific 1.5.8 issue, but who knows.

Jens
--
Last Gallery v1 Developer.
Tryout the TEST-Version of Gallery 1.6

 
jantjebeton

Joined: 2008-08-15
Posts: 1
Posted: Sat, 2008-08-16 07:55

Hi Jens,

Debug enabled, form upload of jpg, result:

save_photos.php::358 -> Now we start processing the given Files. (If they were given)
Error, no photo uploaded.

Ok, just tried to upload the same pic in 1.5.7 and this one says: invalid jpg. That makes sense. I enabled the dutch translation on 1.5.8 and maybe this msg is not translated.

I will look what's wrong with my jpg.

thx,
Michiel

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Sat, 2008-08-16 12:58

Try another image, or does it happen with all images?
What does the ImageMagick / Netpbm Test from the diagnostic page say? (Setup -> Step 1 -> Diagnostic)

Jens
--
Last Gallery v1 Developer.
Tryout the TEST-Version of Gallery 1.6

 
AndrewVasilyev

Joined: 2005-03-24
Posts: 20
Posted: Tue, 2008-08-19 12:26

?&type=views in the bottom URL is not changing while selecting different Type radio buttons: probably, JS doesn't work? Internet Explorer 6.0.
Works as usual in Opera 9.27.

 
nba

Joined: 2007-07-10
Posts: 2
Posted: Mon, 2008-08-25 19:02

I just upgraded from 1.5.7 to 1.5.9-b7 with only one minor problem: the setup wizard fails on choices where the selected index value is "0".

Best regards
/Niels

 
jifl

Joined: 2003-07-06
Posts: 18
Posted: Tue, 2008-08-26 15:59

Hi Jens,

I admit I haven't tried out 1.5.9b7, but I notice your version of the fix for the comments_overview_for_all problem only has checkRequirements('comments_overview_for_all') whereas the previous version had checkRequirements('allowComments', 'comments_enabled', 'hasComments'), so shouldn't it be comments_overview_for_all as well as those three requirements? At the very least has_comments would seem worth checking, to avoid showing the button if there are no comments to show.

I'm also still not personally convinced about the accuracy of the "further hack check" test at the top of view_comments.php, but if you've had a look at it then fair enough.

Jifl

 
AndrewVasilyev

Joined: 2005-03-24
Posts: 20
Posted: Fri, 2008-08-29 22:38

Could you please give back the KOI8-R charset in lib/lang.php:

diff -rbu gallery-1.5.9-b1/lib/lang.php gallery-1.5.9-b13/lib/lang.php
--- gallery-1.5.9-b1/lib/lang.php 2008-08-07 03:01:08.000000000 +0400
+++ gallery-1.5.9-b13/lib/lang.php 2008-08-28 01:43:18.000000000 +0400
@@ -701,7 +709,7 @@
$supportedCharsetsNewerPHP = array(
'cp866',
'cp1251',
- 'KOI8-R'
+ //'KOI8-R'
);

/**

Or is it a Punishment of Russia? :(((

Another strange thing is:

diff -rbu gallery-1.5.9-b1/html_wrap/stats.header.default gallery-1.5.9-b13/html_wrap/stats.header.default
--- gallery-1.5.9-b1/html_wrap/stats.header.default 2008-08-15 02:26:44.000000000 +0400
+++ gallery-1.5.9-b13/html_wrap/stats.header.default 2008-08-23 17:30:58.000000000 +0400
- <td class="head" align="left"><?php echo gTranslate('core', "Gallery statistics") . $stats_title; ?></td>
+ <td class="head" align="left"><?php echo _("Gallery statistics") . $stats_title; ?></td>

(gTranslate() to _()).

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Fri, 2008-08-29 22:16

Hi,

I remember having some trouble with this charset. Don't know what it was. I will reenable it.

True! _() -> gTranslate() is the way to go :-)

Jens
--
Last Gallery v1 Developer.
Tryout the TEST-Version of Gallery 1.6

 
piploff

Joined: 2008-08-27
Posts: 22
Posted: Thu, 2008-09-04 03:50

Hi Jens,
How can I change font-size in selectbox's?
I try used RU.utf8 and RU.cp1251 locale, looks is very huge ;(

 
Tim_j
Tim_j's picture

Joined: 2002-08-15
Posts: 6818
Posted: Thu, 2008-09-04 08:19

Hello,

this does not looke like a specific 1.5.8 BUG.
For such things please open a separate thread.

Edit the screen.css of your Gallery skin. I will delete your and my post this afternoon.

Jens
--
Last Gallery v1 Developer.
Tryout the TEST-Version of Gallery 1.6

 
joshcali

Joined: 2007-10-03
Posts: 19
Posted: Thu, 2009-02-05 22:54

I noticed a bug in 1.5.7 with exif data.
It only displays the first keyword of the "keywords" although there are multiple keywords. Is this bug still present in 1.5.8, does anyone know?