Snitz™ Forums 2000
https://forum.snitz.com/forumTopic/Posts/60218?pagenum=1
04 November 2025, 21:40
Topic
Davecl
MOD Add-On: Latest Albums - updated v1.1
20 November 2005, 02:23
The code for mine & Helters latest albums add-on for Burtholds photo album mode is now available here.
http://www.snitzbitz.com/mods/details.asp?Version=All&mid=45
This add-on displays thumbnails of the latest uploaded pic in 20 albums, very easy to install and can be modified to display any number of albums.<
Replies ...
Helterskelter
20 November 2005, 03:22
Davecal done all the hard work.
How ever It's good that some one has at last figered out a way to do this.
Helter<
Helterskelter
20 November 2005, 03:31
You need running the " burthold's" photoablum 1.82mod
Of course if you have configered to upload to a different file, then you'll have to change from albums (default) to your new folder.
Helter<
Classicmotorcycling
20 November 2005, 06:09
OK, I have used your MOD, but had to adjust a few things in it, but got it working with a simple 2 lines at the top of the file that needs changing to the one file to make it work for me easier. I also took away the need to adjust your red code above to make it easy for users.
I have a demo of it working at http://www.vncommodore.com/forum/ <
Davecl
21 November 2005, 04:14
Thanks David, glad you got it working<
richfed
21 November 2005, 07:03
How may I change the font size for the members' names that appear with their recent photo?<
This will now call the text formatting of the forum.
Helter<
richfed
21 November 2005, 17:20
Much better ... thanks!<
Helterskelter
21 November 2005, 17:44
No probs. Just need the download file reziped at some point.<
Classicmotorcycling
23 November 2005, 13:35
OK, found a slight issue with the code. The actual photos do not update on the front page. I will give an example:
I have set the display to 10 photos (on a site not for the public) and it displays the first 10 users in alphabetical order (which will consist of say 3 users starting with A, 4 starting with D, 2 starting with F and 1 with H), but when a user with a name that starts with I or above updates their photo album, the photos do not change on the front page. In other words their phot doesn't show on the front page.
Any help getting this resolved would be great.
<
imweazel
23 November 2005, 14:41
Originally posted by Classicmotorcycling OK, found a slight issue with the code. The actual photos do not update on the front page. I will give an example:
I have set the display to 10 photos (on a site not for the public) and it displays the first 10 users in alphabetical order (which will consist of say 3 users starting with A, 4 starting with D, 2 starting with F and 1 with H), but when a user with a name that starts with I or above updates their photo album, the photos do not change on the front page. In other words their phot doesn't show on the front page.
Any help getting this resolved would be great.
Try changing the SQL statement to use TOP for Access and LIMIT for SQL and if you order by the primary key in a descending fashion you should get the last 10 entries made to the table. Something like this:
SELECT TOP 10 FORUM_ALBUM.Photo_id, FORUM_ALBUM.Photo_Name AS ID, FORUM_ALBUM_USERS.M_NAME, FORUM_ALBUM.Member_id FROM FORUM_ALBUM, FORUM_ALBUM_USERS WHERE (((FORUM_ALBUM.Member_id)=[FORUM_ALBUM_USERS].[MEMBER_ID]) AND ((FORUM_ALBUM.Photo_Status)=1)) GROUP BY FORUM_ALBUM.Photo_id, FORUM_ALBUM.Photo_Name, FORUM_ALBUM_USERS.M_NAME, FORUM_ALBUM.Member_id ORDER BY FORUM_ALBUM.Photo_id DESC;
<
Davecl
24 November 2005, 16:28
TOP doesn't work because that will give you the last 10 albums that were updated even if all 10 were from the same member which is not what i intended, you need to use MAX to get it to skip albums with more than one recent uploaded pic.
don't know why it's not working David, It's working fine on my forum, although i'm using 20 not 10. i'll take a look when i get chance.<
Davecl
24 November 2005, 17:53
had a look and you are right david, silly me, as it stands you would have to show all the records that the sql creates to show all your latest updated albums. I will have to look into the sql.<
Classicmotorcycling
25 November 2005, 03:50
Cool... I thought that it was me for a second there.. If you could look in to it, then it would be great.
Originally posted by Davecl had a look and you are right david, silly me, as it stands you would have to show all the records that the sql creates to show all your latest updated albums. I will have to look into the sql.
The site I have it on has more than 1000 members and you do not want to show than many images on the page.. <
Davecl
28 November 2005, 04:52
New version - V1.1
Changed the SQL so it should now work correctly, showing the latest updated albums in descending order.
Added tool-tips to picture links
Usernames now display in the default forum font.
http://www.snitzbitz.com/mods/details.asp?Version=All&mid=220
For all interested, I'm using a double way to view thumbnails: 6 thumbs in the forum homepage and 18 in the Photo Album main page (photo_album .asp). In this way, more users are happy because their photos are viewable.
You can take a look at www.discusclub.net , scroll down and click on "Discus Forum Foto Album" link
To do this, I've used another inc_latestalbumthumb2.asp file (I've renamed it inc_latestalbumthumb2a.asp), calling it as include in photo_album.asp in this way
" </tr>"& vbNewLine & _ "</table>"& vbNewLine %> <!--#INCLUDE FILE="inc_latestalbumthumb2a.asp"--> <% 'this is the top nav 3.4 will be compliant as soon as I get around to it ;)
Well, I know is a little thing, but hope someone can find useful the idea <
Davecl
22 December 2005, 00:52
excellent idea.<
rabufo
22 December 2005, 01:10
Thank you Davecl, happy you like it <
Helterskelter
23 December 2005, 02:30
Looks good.
I noticed u added a Camera Icon. Thats something I missed and should of added, How ever a good way to remind me to add it in.
Helter<
rabufo
23 December 2005, 12:12
Let me know if you need the code I've used to add the camera icon, Helter....<
Helterskelter
23 December 2005, 21:09
welcome to post will save me 10 mins LOL<
rabufo
24 December 2005, 03:25
here the related inc_photo_album_update2.asp
<% '################################################################################# '# Copyright (C) 2000-02 Wesley D. Brown '# Photo Album v.05 for Snitz 3.3.05 '# This is include for default.asp it builds the small table needed for navigation '################################################################################# '################################################ 'Latest Albums Add-On by Dave Clarke & Alan Dunne '################################################
Does anyone know how to adjust the SQL so that only photo's marked as 'Visible' show up in the latest photos?
I have tried inserting 'AND FA1.Photo_Status = 1' to various places in the sql however I can't get it to work.
Thanks<
Davecl
12 February 2006, 02:50
thought i'd updated the files in the mod to do this but obviously not, i'll do it later, in the meantime alter the sql to this
strSql= "SELECT FA1.Photo_id, FA1.Photo_Name, FAU1.Member_id, FAU1.M_NAME FROM FORUM_ALBUM_USERS AS FAU1 INNER JOIN FORUM_ALBUM AS FA1 ON FAU1.Member_id = FA1.Member_id WHERE (((FA1.Photo_id)=(SELECT MAX(FA01.Photo_id)FROM FORUM_ALBUM AS FA01 WHERE FA01.Member_id = FA1.Member_id GROUP BY FA01.Member_id)) AND ((FA1.Photo_Status)=1))ORDER BY FA1.Photo_id DESC;"<
Davecl
13 February 2006, 12:08
updated the mod to include the new sql that only shows approved photos.
http://www.snitzbitz.com/mods/details.asp?mid=220
<
ian9001
20 March 2006, 15:37
Nice Mod I've used on several forums using MS Access, thanks guys. Now trying to use it on a forum using MySql Ver 5 and keep getting:
#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'SELECT MAX( FA01 . PHOTO_ID ) FROM FORUM_ALBUM AS FA01 WHERE FA
I've tested each part of this query using phpMyAdmin and it all works fine. Run it together and I get the above error. I'm afraid my knowledge of SQL is limited (I am trying!) and the various changes I made just got me deeper into the variety of error messages.
The Mod version I'm using is the latest one uploaded.
A pointer as to why this script keeps falling over would be cool..
Ian<