PDA

View Full Version : Show Thread Enhancements - Album Link in Postbit


h2ojunkie
12-08-2008, 10:00 PM
Adds a link to the userinfo section of showthread and showpost only if user has public albums.

Uses postbit_userinfo_right template hook for position of the link, so there are no template edits.

Uses one sub query.

I have not tested this on any version other than 3.8.0 RC 1

I have only tested on a small site, and while I don't expect there to be a performance issue, I can not confirm it's performance effect on large sites with a large number of user albums.

SEOvB
12-09-2008, 10:01 PM
isn't it going to add a query to every post on the page?

h2ojunkie
12-09-2008, 10:20 PM
No, it's one query for the entire page no matter how many posts are on that page, and it's actually a left join sub query on the main VB query that grabs the posts for that page. So in theory it may actually be a little less load than a stand alone query would be.

SEOvB
12-09-2008, 10:47 PM
No, it's one query for the entire page no matter how many posts are on that page, and it's actually a left join sub query on the main VB query that grabs the posts for that page. So in theory it may actually be a little less load than a stand alone query would be.

Awesome job then :up:

Daryn
12-09-2008, 11:57 PM
Would there be a way to get this to work on the postbit_legacy?

SEOvB
12-10-2008, 11:26 AM
Would there be a way to get this to work on the postbit_legacy?

Make sure you have: $template_hook['postbit_userinfo_right'] in your postbit_legacy template.

Works good for me in both postbit and postbit_legacy

alqloob alsahya
12-11-2008, 07:33 PM
Excellent

Thank you for your beautiful theme

I've change instead of a simple text link and replace them with the adjustment method is easy, the way language and words

Search Member's Picture Albums
B replace them

<a href="album.php?u=$post[userid]" title="View $post[username]'s Album" rel="nofollow"><img src="images/buttons/add_album.png" alt="Member's Picture Albums" border="0"/></a>

And easily change the language of the text explanation as a state language only change Member's Picture Albums shown in red

Image upload to your site


https://vborg.vbsupport.ru/



Just a slight change to the participation of your themes beautiful

Thank you again :up:

joh
12-12-2008, 06:58 AM
Can this be made to show the number of images the users have in his/her album/albums?

Sweeks
12-12-2008, 11:44 AM
Not working in 3.7.4 PL1, tried changing the hook to $template_hook[postbit_userinfo_right_after_posts], didnt show still in postbit_legacy for me. Would appreciate if anyone else knows how to get this working in 3.7.4PL1 Thanks
________
Fix ps3 (http://fixps3.info/)

h2ojunkie
12-12-2008, 03:37 PM
Can this be made to show the number of images the users have in his/her album/albums?
It may be possible, but that would require extra queries. Not something I plan to do as I have no need for the image count at the cost of extra queries.

ejbreeze
12-30-2008, 08:39 PM
Not working in 3.7.4 PL1, tried changing the hook to $template_hook[postbit_userinfo_right_after_posts], didnt show still in postbit_legacy for me. Would appreciate if anyone else knows how to get this working in 3.7.4PL1 Thanks

Please share if you get it working ...Thanks

anestetic
12-31-2008, 10:09 AM
haw many picture in album in postbit

xTerMn8R
01-08-2009, 12:31 AM
Can someone explain to me the difference between Postbit and Postbit_legecy
I'm a Beginner at coding php and vBulletin

Thanks...
Tom

rolandogomez
01-09-2009, 03:57 AM
For the non-coders, can you tell me where to put this code (after we loaded the product xml)? I'm using postbit legacy. Thanks!

SonicGT
01-09-2009, 08:47 PM
Can someone explain to me the difference between Postbit and Postbit_legecy
I'm a Beginner at coding php and vBulletin

Thanks...
Tom

Postbit_legacy is the older vb style where the user info is on the left and the post the right of the thread, the postbit is the newer look where it has all the user info on the top then the post below, so a horizontal seperator rather then verticle basically if that makes sense

I have 2 sites one with legacy use and 1 with newer
Here is an example of legacy (modded slightly)
http://www.nextgenmusclecars.com/forums/showthread.php?t=3371

and an example of the normal postbit (modded slightly)
http://windycitystangs.com/forums/showthread.php?t=4

Idawg
01-10-2009, 10:48 PM
For the non-coders, can you tell me where to put this code (after we loaded the product xml)? I'm using postbit legacy. Thanks!

Im with him

Postbit_legacy is the older vb style where the user info is on the left and the post the right of the thread, the postbit is the newer look where it has all the user info on the top then the post below, so a horizontal seperator rather then verticle basically if that makes sense

I have 2 sites one with legacy use and 1 with newer
Here is an example of legacy (modded slightly)
http://www.nextgenmusclecars.com/forums/showthread.php?t=3371

and an example of the normal postbit (modded slightly)
http://windycitystangs.com/forums/showthread.php?t=4

I think he wants to know WHERE to put the $template_hook['postbit_userinfo_right'] code in postbit_legacy. I am having the same problem as Roland is

glennybee
01-18-2009, 01:41 PM
Find the following code and add it before it:

<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] $post[skypeicon]</div>

So it should look like this:

<if condition="$show['infraction']"><div>$vbphrase[infractions]: $post[warnings]/$post[infractions] ($post[ipoints])</div></if>
<if condition="$show['reputation']"><if condition="$show['reppower']">$vbphrase[reppower]: <span id="reppower_$post[postid]_$post[userid]">$post[reppower]</span> </if><div><span id="repdisplay_$post[postid]_$post[userid]">$post[reputationdisplay]</span></div></if>
$template_hook[postbit_userinfo_right]
<div>$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] $post[skypeicon]</div>

Marvin Hlavac
01-20-2009, 11:30 AM
Other than importing the .xml file, do I need to do anything else to enable this feature? I just imported the file, but I don't see it working for members who do have albums. Could it just be that I'm using an older vbulletin 3.7.3?

wottech
01-20-2009, 04:21 PM
I installed it on a 3.7.3 forum and it did not work. I upgraded to 3.8.0 and it worked just fine without me having to do anything. So I am assuming that it does not work pre-3.8.

DieselMinded
03-06-2009, 10:51 PM
<a href="https://vborg.vbsupport.ru/showthread.php?p=1762109#post1762109" target="_blank">https://vborg.vbsupport.ru/showt...09#post1762109</a>

Allan
03-08-2009, 10:27 AM
Thank you :)

Work on vB 3.8.1.

Redzzand
03-12-2009, 06:14 PM
great mod but is there any way to change it to use $template_hook[postbit_userinfo_left]?

DobieGillis?
03-12-2009, 06:37 PM
Excellent

Thank you for your beautiful theme

I've change instead of a simple text link and replace them with the adjustment method is easy, the way language and words

Search Member's Picture Albums
B replace them

<a href="album.php?u=$post[userid]" title="View $post[username]'s Album" rel="nofollow"><img src="images/buttons/add_album.png" alt="Member's Picture Albums" border="0"/></a>

And easily change the language of the text explanation as a state language only change Member's Picture Albums shown in red

Image upload to your site


http://forums.ql-b.com/images/buttons/add_album.png



Just a slight change to the participation of your themes beautiful

Thank you again :up:

where did you edit this to add a picture to replace the text? Anyone?

Markos
03-12-2009, 07:27 PM
where did you edit this to add a picture to replace the text? Anyone?

search in Phrase's

Markos
03-12-2009, 07:29 PM
hmm ive just installed this and wen i click on it i go to my own album :S

Redzzand
03-12-2009, 07:34 PM
if you want to change the template_hook; simply edit the XML file and change $template_hook['postbit_userinfo_right'] to $template_hook['postbit_userinfo_left']

re-import XML and allow overwrite

BigDog56
03-12-2009, 07:37 PM
Very nice! Works great and Thank You!

DobieGillis?
03-12-2009, 08:11 PM
search in Phrase's

thanks

Markos
03-12-2009, 08:19 PM
thanks

np anytime

can anyone tell me if it takes them to there own album instead of the user who u click on ???

Redzzand
03-12-2009, 08:46 PM
it takes me to the proper user's album... working properly on my board

Markos
03-12-2009, 10:49 PM
did you do the edit with the image ??

DobieGillis?
03-12-2009, 10:52 PM
did you do the edit with the image ??

not good with phrases, thats new to me. I guess I have to install the mod forst to find the phrase?

Markos
03-13-2009, 12:04 PM
Search for Member's Picture Albums

and wen u click edit it will open it and in the empty box place this in it

<a href="album.php?u=$post[userid]" title="View $post[username]'s Album" rel="nofollow"><img src="images/buttons/add_album.png" alt="Member's Picture Albums" border="0"/></a>

and save it

woffie
03-16-2009, 12:18 AM
Tried it, did not work.

MikesSite
04-02-2009, 11:15 PM
After toying with this I got it to work properly w/ the image in postbit. I've attached the modified XML version of the developers original post. If he minds I will remove it, but I dont see why he would.

You need images/buttons/add_album.png

RedHacker
04-06-2009, 06:45 AM
Its work fine thanks.....

bbau01
04-11-2009, 02:50 PM
Marked as installed, 2 sec install - working perfectly - thanks!

asabet
04-15-2009, 10:28 PM
Works great, thanks!

DobieGillis?
04-15-2009, 11:58 PM
After toying with this I got it to work properly w/ the image in postbit. I've attached the modified XML version of the developers original post. If he minds I will remove it, but I dont see why he would.

You need images/buttons/add_album.png

well done, mate! Worked like a charm!

woffie
04-16-2009, 03:06 PM
Installed now that there is a version for Legacy.

DieselMinded
04-18-2009, 09:34 PM
what do i need to do to use an image instead for the link?

Namaless
04-27-2009, 07:44 PM
Italian Language for 0.9

gg2-hungama
05-19-2009, 10:59 PM
sorry i m new instead of postbit can anyone tell me how can i add Pictures & albums to my navbar instead of i have to click on community and it expands and then pictures& albums but i want ppl to see it right on navbar where newbiis can find easily can anyone tell me the template edit and what code for that ?? thanks in advance

ricardoNJ
05-29-2009, 06:29 PM
Thanks!

DieselMinded
06-06-2009, 05:45 PM
how do i use an image under location and ect on post bit insted for a link?

Daisyboo
08-16-2009, 03:11 PM
Worked great, but how would I add a space either above or below the text link?

Dimoks
08-31-2009, 08:51 PM
dont working with vb 3.8.3 :(

h2ojunkie
09-01-2009, 03:40 PM
dont working with vb 3.8.3 :(

I'm currently using it in 3.8.4 and I used it in 3.8.3 and it works in both.

You must have a template edit in your postbit that is interfering with it.

dr nick
09-05-2009, 12:01 PM
How do i change the name " Member's Picture Albums " to something else?

biggeorge
11-13-2009, 11:47 AM
Installed and working fine with 3.8.1

biggeorge
11-13-2009, 12:10 PM
How do i change the name " Member's Picture Albums " to something else?

I'd like to change it too. Any help would be appreciated.

Skydiver10
11-16-2009, 02:49 AM
How can I move the link to the other side of the page next to the avatar?

iardon
11-17-2009, 03:16 AM
Nice mod, installed.

Skydiver10
11-17-2009, 01:27 PM
Hi there,

I installed this.....but how come it only shows on my posts??

Does anyone know how to have it on members own posts so others can have links to their albums??

Members can see it on my posts, but there is no link on any of the other members post.

Or do members have to sign in to activate the link to their post?

Do I need to edit something? Any help would be greatly appreciated.

g0rdy
12-09-2009, 06:23 PM
Just a note:

If a members first album is set to private the remaining public albums will not show a link in the postbit

Hope that helps anyone that encountered the odd member that doesn't have the link working :)

-gordy

Skydiver10
12-09-2009, 08:04 PM
I was wondering about that, I almost emailed a member and was going to ask them to re-upload their pictures. Found out that their album is set to private.:eek:

Allan
12-13-2009, 05:33 AM
Work onv B4 ?

XcYZ
01-18-2010, 03:26 AM
I'm getting an invalid SQL error:

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 'SELECT state, userid, MAX(albumid) AS hasalbum FROM album GROUP

I'm running 3.8.4 PL2, SQL version 4.0.27-standard. The only add-on is All Albums 2.5 (https://vborg.vbsupport.ru/showthread.php?t=172215).


Any suggestions what I may be doing or have wrong?

aberg
02-11-2010, 06:34 PM
Work onv B4 ?
Yes, works also with Vb4.01

Cybershaolin
02-15-2010, 02:22 PM
When I look in a thread's post, I get this error after importing the product. (I just imported the product without changing anything else...)

Parse error: syntax error, unexpected T_STRING in ...\forum\includes\class_postbit.php(265) : eval()'d code on line 43


I used the product here: https://vborg.vbsupport.ru/showpost.php?p=1800126&postcount=42

Why's that?

Cybershaolin
02-15-2010, 04:57 PM
OK, I got it working with the picture but the only way which worked for me is to replace the code with this one:


$template_hook['postbit_userinfo_right'] .= '<div><a href="album.php?' . $vbulletin->session->vars['sessionurl'] . 'u=' . $post['userid'] . 'rel="nofollow">' . '<img src="images/buttons/add_album.png" border="0" alt="Member Photo Albums" /> ' . '</a></div>';

horussjr
03-05-2010, 07:30 PM
update for 4.0?

aberg
03-05-2010, 07:45 PM
Works with VB4

Tanapangarap
06-14-2010, 10:08 PM
Hi.

Thank you for this modification. I am using the version of the modification with a minor edit by MikesSite (shown here: https://vborg.vbsupport.ru/showpost.php?p=1782759&postcount=35 ) which changes the link to an image. I was wondering, though, how I may change the location so that the image would be to the right of the IM icons and in the same row, rather than on top of them. Here is a screen shot:

https://vborg.vbsupport.ru/attachment.php?attachmentid=118473&stc=1&d=1276556838
I would like for that album picture to show up next to those IM icons, with the proper spacing (i.e., how the IM icons are spaced from each other).

Any ideas?

Regards,

Kevin

KURTZ
06-21-2010, 09:48 AM
Works with VB4

not really ... check the pic ;)


someone can help me to put the link under the blogs?

M? CaMPa
06-22-2010, 03:00 PM
thank you

realdx
07-16-2010, 03:27 PM
One click install and perfectly working on 3.8.4.. Thank you so much!

MikesSite
12-14-2010, 02:07 PM
what do i need to do to use an image instead for the link?

https://vborg.vbsupport.ru/showpost.php?p=1782759&postcount=35

Blueracer66
12-15-2010, 10:22 AM
One click installed. Works fine in vBulletin 3.8.6 Patch Level 1. :)

risestar
01-27-2011, 09:47 PM
This also works on Vbulletin 4, tested on 4.1

inciarco
01-27-2011, 10:24 PM
Great Mod, Thank You For Sharing It. :up:

Is it Possible to Extend this Functionality to the Memberlist? :confused:

It'd be Great for Members that Consult the Memberlist to be Able to Have a Link Below the Usernames for the Members that Have Album, (for the Members that don't have one No Link would be Created). ;)

My Best Regards.

:)

viper357
07-09-2011, 07:59 PM
I have only tested on a small site, and while I don't expect there to be a performance issue, I can not confirm it's performance effect on large sites with a large number of user albums.
Has anybody installed this on a large site and noticed any performance issues? Thanks.

gezuvor
03-02-2012, 08:29 PM
I am modifying this and wanted to know if anyone could suggest a way for me to get the album count in the postbit?

HM666
11-19-2018, 01:51 AM
Tested and works in vB 4.2.5! :)