Cool. Let me know as you have versions you need tested and I'll put them up as soon as possible.
Rev 359 fixed my cache dir issue and sharpened thumbs are working great Initially I added the thumb_sharpen line to the top of zp-config.php before I noticed you had an existing one set to false further down in the file.
I believe the previous issues I mentioned in regards to the previous/next entries getting a bit fubar'd are the same as this issue. In my case I was changing around and renaming albums and files, but the garbage collection doesn't seem to be finding the orphaned entries (or maybe i'm misunderstanding what it should do?). For example, if I completely clear out the albums and cache subdirs and click on the admin refresh option, it's currently showing it has 107 images in 9 albums. The quick fix for me seemed to be to manually drop and recreate the database.
Speaking of which, setup.php fails for me when trying to create tables on a fresh db, failing with the error below. In the interim i've been using ZP 1.0.7 to create them. I replaced the backticks in the error message with "+":
`Creating tables...
MySQL Query ( CREATE TABLE IF NOT EXISTS ++albums++ ( +id+ int(11) unsigned NOT NULL auto_increment, +parentid+ int(11) unsigned default NULL, +folder+ varchar(255) NOT NULL default '', +title+ varchar(255) NOT NULL default '', +desc+ text, +date+ datetime default NULL, +place+ varchar(255) default NULL, +show+ int(1) unsigned NOT NULL default '1', +thumb+ varchar(255) default NULL, +sort_type+ varchar(20) default NULL, +sort_order+ int(11) unsigned default NULL, PRIMARY KEY (+id+), KEY +folder+ (+folder+) ); ) Failed. Error: Incorrect table name ''`
Two other things I noticed and weren't sure if they were working as intended or not:
-If you remove theme.txt from the cache dir, zp loses its current theme and reverts to the default one instead of recreating the theme.txt file.
-Photos in the albums dir that aren't otherwise in an album of their own don't show up when viewing the main zp page.
Sorry for long-winded posts :/
Rev 360 worked smashingly. At the risk of sounding cliche, you da man Tris.
Hi,
the subfolder work in view mode with no error, but i'm not able to sort or edit subfolder.
Continue your good work. I'm a futur user, i only need to be able to use subfolder to change to your album. Very nice, simple et good looking. Exactly what i need!
Thx a lot
bumpert
@bumpurt-
if you mean you're needing to sort subalbums, which I'm assuming you are, then that feature is coming in a future release soon. currently there is no interface in the admin for sorting and manipulating subalbums. you can still utilize FTP to rearrange albums and such, but you won't be able to "sort" images until the admin has the facility in place for it.
You can keep an eye on the roadmap at: http://www.zenphoto.org/trac/roadmap
It looks like v1.1 is the target for that functionality.
@bitbybit - Thanks immensely for the bug reports, that's a huge help. Yes, I do need to work on garbage collection bigtime, and test things out with duplicate/extra entries lying around as well. Zenphoto shouldn't choke regardless of what's in the database.
Glad to hear sharpening is working. I've set it pretty low by default, but that'll eventually be in zp-config.php as well.
The setup/upgrade problems have been resolved; I moved the adding of those backticks to the prefix() function, so the table names were getting double-backticked. I've removed them and the latest SVN's setup/upgrade should now work.
Those last two items are expected behavior. The theme.txt is where the current theme is stored, so without it, zenphoto doesn't know what theme you set and has to go back to the default. That will be moved to the database with an options screen in the admin in 1.1 or 1.2. Images in the root /albums folder aren't displayed because they're not in an album, so that's expected as well. Let me know if you think they should be shown somewhere, like in a "Root" album or something.
Rev 363 setup.php working great
Regarding root images, it seems more intuitive to me that all images in /albums and below should be displayed somehow. I would tend to lean towards having /albums be a pseudo-album itself, meaning that any photos located in /albums would be displayed when visiting blah.com/albums/, along with the subalbums also located there.
I'm definitely not married to to that solution though. Anything that would avoid the blackhole that is currently an image in the /albums root dir would be good And certainly a low priority request at that
Here's an interesting one that I just noticed:
Why would this function output incorrect URLs? The URL is structured like:
http://www.bushwoodworking.com/zenphoto/projects%2Fbushwoodshop%2Fdirtcheapcabinets/IMG_2908.JPG
and the function:
`function getURL($image) {
if (zp_conf('mod_rewrite'))
{
return WEBPATH . "/" . urlencode($image->getAlbumName()) . "/" . urlencode($image->name);
}
else
{
return WEBPATH . "/index.php?album=" . urlencode($image->getAlbumName()) . "&image=" . urlencode($image->name);
}
}`
I'm running Rev 363 from SVN.
Bingo. urlencode was screwing up the paths on the mod rewrite. this works better:
`function getURL($image) {
if (zp_conf('mod_rewrite'))
{
return WEBPATH . "/" . $image->getAlbumName() . "/" . urlencode($image->name);
}
else
{
return WEBPATH . "/index.php?album=" . urlencode($image->getAlbumName()) . "&image=" . urlencode($image->name);
}
}`
Any other glaring errors that are noticeable? Should I remove urlencode entirely from the mod_rewrite section?
I've got a pathurlencode() function for that very purpose (splits by / before urlencoding), I just forgot it there. I'll add it and check it in later.
On a side note, how you you guys feel about using a different character for spaces in the URLs? I'm tired of seeing all those %20's, it's rather messy. The idea would be to convert the URL's in the link functions, then when looking at the paths, look for a folder with the exact name first, then one with the space character (probably a dash -) replaced with spaces. Should cover all the bases.
Yup. It's part of the random image function. It's used in my themes, grabbed it off the forums here a while back, and Stephane also uses it in her Effervescence theme. I'll make sure to update her as well for future reference. If you have another function that accomplishes the same goal I'd be glad to use that instead and have less custom functions floating around....
Do I need to use that pathurlencode for the non-mod-rewrite option in that function as well? Didn't test it with mod_rewrite off yet.
And I'm cool with another character for spaces. I'm of the same opinion that the %20 looks kind strange.
Here's a snippet from Effervescence so you can see what I mean:
`