View Full Version : Photopost vba gallery module
acers
12-21-2005, 07:38 AM
Before i even give the code,
let me say that i made this module for my site based on what i wanted. It certainly is not the comprehensive module you see as "display images on forumhome" kind where you have the image info also being displayed (although doing this would be easy.. but i didn't cos i didn't need :) )and checks for permissions.
I just wanted a teaser of my gallery to be shown in the movie section and so i used this.
I am releasing the module code for you guys. Geek,, just have a look if i am not doing something atrocious :p i haven't got the hang of caching so i just saw one of your module code and added the caching part to mine
USAGE:
Put the vbgallery.php file to your mods folder
thats geek/gars/mods
go to modules, select register new module
add vbgallery.php
you don't need to cache template cos its anyway cached but enter
GARS_mod_container
give suitable title
save
go to module sets...
place the module anywhere you want
you have following options
Important: this assumes that your gallery is under gallery/ folder. If not edit the file
1) which cats to take image from
2) how many to take
3) vertical or horizontal
demo:
horizontal: http://www.techenclave.com/forums/king-kong-64183.html
vertical: http://www.techenclave.com/forums/movie-reviews/
if this goes ok i will release some more mods :)
The Geek
12-21-2005, 08:28 AM
hey cool. Ill take a look at it a little later. THannks!
DerTobi75
12-21-2005, 01:18 PM
Thanks for sharing acers!
Stachel
12-26-2005, 06:06 PM
Acers,
The title links of the articles, as well as the "..." link, all go to dead pages.
http://www.techenclave.com/forums/movie-reviews/
Stachel
acers
12-27-2005, 06:10 AM
umm u sure..
its ok for me
just checked.. all are going to the right places
zgeek
12-30-2005, 02:06 AM
Is it possible to set it to show only images relating to review to the review? At the moment you can only specify a few gallerys which show random images for all reviews...
acers
12-30-2005, 03:03 AM
would it help if i add a option when you edit the post to add the image ids of image?
and then it will show only those image ids.. randomizing between them
basically i added galleries as those are one time for all forums.. but if you want i can do it that way also.
btw have a look at this ... just in case this is what you need
http://www.vbulletin.org/forum/showthread.php?t=99011&highlight=geek+gallery
a mod by our very own geek :)
zgeek
12-30-2005, 07:29 AM
Adding image ids would be great. Would this be able to be set for individual reviews?
acers
12-30-2005, 08:35 AM
yep... can make that available at edit time or creation time..
you want randomization or all of them to be displayed?
zgeek
12-31-2005, 03:48 AM
Having them show all at once would be best. Thanks heaps for doing this :)
acers
12-31-2005, 09:41 AM
hi np..
will do it in the new year.. :)
Ramses
01-10-2006, 05:00 AM
would it help if i add a option when you edit the post to add the image ids of image?
and then it will show only those image ids.. randomizing between them
basically i added galleries as those are one time for all forums.. but if you want i can do it that way also.
btw have a look at this ... just in case this is what you need
http://www.vbulletin.org/forum/showthread.php?t=99011&highlight=geek+gallery
a mod by our very own geek :)
Thank you for this modification, it would be great if you could do it with the image id's.
I need only one image instead of 4 and the possibility instead the standard header image module the option to give also a image id for the thumbnail picture of the gallery.
Only if it's not to much work, thanks.
zgeek
01-23-2006, 02:13 AM
Any word on this?
acers
01-27-2006, 03:33 PM
forgot ll about this
:D
sorry will release it soon.
zgeek
02-16-2006, 01:54 AM
Thanks dude.. a image module like this is going to make GARS very, very sexy.
Ramses
03-06-2006, 07:03 AM
Wanted to change the path from www.mydomain.com/forum/gallery to www.mydomain.com/gallery
Original code:
$images[url]=$vbulletin->options['bburl'] . '/gallery/files/' . implode('/', preg_split('//', $images[userid], -1, PREG_SPLIT_NO_EMPTY));
Changed code:
$images[url]=$vba_options['gallery_url'] . '/gallery/files/' ;
So far it was working, but if somebody was writing a comment the gars thread wasn't more accessible and get following error:
Die Cookies konnten nicht gesetzt werden, da der Header schon an den Browser geschickt wurde.
Datei: /home/www/web153/html/forum/geek/gars/mods/vbgallery.php
Zeile: 71
Anybody can help me?
Seiken
03-15-2006, 09:09 PM
I get this error.
Database error in vBulletin 3.5.0:
Invalid SQL:
SELECT imageid, userid, images.title, filename, thumbname, originalname, extension, images.catid
FROM adv_gallery_images AS images
WHERE images.catid in ()
ORDER BY RAND()
LIMIT 5;
MySQL Error : 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 ')
ORDER BY RAND()
LIMIT 5' at line 3
Error Number : 1064
Date : Wednesday, March 15th 2006 @ 04:02:53 PM
Script : http://www.gameinformerz.com/showthread.php?p=1725
Referrer : http://www.gameinformerz.com/forumdisplay.php?f=120
IP Address : 24.186.130.28
Username : Seiken
Classname : vb_database
Im using PhotoPost 5.2 Pro and VB3.5.0
heck ..i like what you did on the bottom there...that looks friggin nice.
I get this error.
Database error in vBulletin 3.5.0:
Invalid SQL:
SELECT imageid, userid, images.title, filename, thumbname, originalname, extension, images.catid
FROM adv_gallery_images AS images
WHERE images.catid in ()
ORDER BY RAND()
LIMIT 5;
MySQL Error : 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 ')
ORDER BY RAND()
LIMIT 5' at line 3
Error Number : 1064
Date : Wednesday, March 15th 2006 @ 04:02:53 PM
Script : http://www.gameinformerz.com/showthread.php?p=1725
Referrer : http://www.gameinformerz.com/forumdisplay.php?f=120
IP Address : 24.186.130.28
Username : Seiken
Classname : vb_database
Im using PhotoPost 5.2 Pro and VB3.5.0
this is for vba gallery not pp gallery
can something like this be made for photopost pro? with category ID's so that it displays only photos from certain categories instead of just random pictures. this would be a perfect addition to the GARs scrip imo.
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.