vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   Forum Display Enhancements - Digital Point Thread Avatars (https://vborg.vbsupport.ru/showthread.php?t=271540)

alfanexus 10-08-2011 09:06 AM

very nice :) Thanks!

digitalpoint 10-08-2011 09:25 AM

Quote:

Originally Posted by FF|Skyrider (Post 2254599)
Can this be disabled by the user if the user doesn't like the new changes?

No, sorry.. it's not a per user thing. It's either on or off for the site.

Skyrider 10-08-2011 09:51 AM

Quote:

Originally Posted by digitalpoint (Post 2254612)
No, sorry.. it's not a per user thing. It's either on or off for the site.

Quite a shame actually. Would be great if it would be on by default, but the user given the ability to disable it.

sdebank 10-08-2011 11:08 AM

Lovely mod.

MrEyes 10-08-2011 12:10 PM

Looks good, one question though:

Does this mod respect the usercp option to disable viewing avatars?

i.e. If the user has chosen to disable avatars for their account, does this mod still display the avatars or something else?

alfanexus 10-08-2011 02:35 PM

Quote:

Originally Posted by digitalpoint (Post 2254102)
If you don't want the icon/avatars to be 60% opacity when there is nothing new to read, just remove the "opacity:0.6" line from the dpta.css template.

But by default, that's the intended behavior. 100% when there's new posts to read in the thread, 60% when there is not.

I would like to set it to 100% all the time, but I could not find the "opacity:0.6" in the dpta.css template. Has this been changed?

digitalpoint 10-08-2011 06:34 PM

Quote:

Originally Posted by FF|Skyrider (Post 2254631)
Quite a shame actually. Would be great if it would be on by default, but the user given the ability to disable it.

I had thought about making it a per user setting, but then I decided to go a more flexible route (which I haven't implemented quite yet). I'm going to have the system read a $show variable for it. That way a site owner could make a simple plug-in to hide it based on any logic they want (could be a setting they have via a custom profile field... or maybe by user group, or per style, etc.)

Quote:

Originally Posted by MrEyes (Post 2254662)
Looks good, one question though:

Does this mod respect the usercp option to disable viewing avatars?

i.e. If the user has chosen to disable avatars for their account, does this mod still display the avatars or something else?

It does because the system does not really consider it an avatar at that point, there would need to be a setting to disable thread icons for something like that to work. But that being said, see response above, because you will be able to disable it based on any logic you see fit (such as the user setting to disable avatars).

Quote:

Originally Posted by alfanexus (Post 2254723)
I would like to set it to 100% all the time, but I could not find the "opacity:0.6" in the dpta.css template. Has this been changed?

Ick... My apologies, I thought I had moved that to the CSS, but after checking, it's still in the template_compile plug-in. As a quick fix, go into that plug-in, and there are two places that "opacity:0.6" exist... just change them to "opacity:1". Then go to AdminCP -> Maintenance -> Update Counters -> Compile Thread Avatar Templates

I've since moved that styling to the CSS file (for real this time), so it will be there for the next version.

digitalpoint 10-09-2011 01:00 AM

Changed for 1.03...
  • Moved opacity CSS to dpta.css template
  • Overlayed lock icon spills out of thread icon a bit
  • Added $template_hook['thread_avatars'] so you can add custom things to the thread icon
  • Added ability to disable add-on on a per page generation basis via $show['hide_thread_avatars'] variable

digitalpoint 10-09-2011 01:29 AM

Since I'm sure someone will ask how to make a custom setting that users can use to disable Thread Avatars just for themselves, you can go to AdminCP -> User Profile Fields -> Add New User Profile Field

Choose the "Single Selection Radio Buttons" option. These are the settings I use for digitalpoint.com:

https://vborg.vbsupport.ru/external/2011/10/60.png

An important thing to note is what the internal field ID is for your new setting. In my case it's 21... so in the plug-in, we are reading field21.

Create a new plug-in like so (do NOT pick the Thread Avatars as the product since it would get overwritten on an update):

https://vborg.vbsupport.ru/external/2011/10/61.png

You now should have a setting that users can set in their UserCP settings that allows them to toggle Thread Avatars on/off.

You can use a similar plug-in to set the $show['hide_thread_avatars'] variable to "true" for other things if you want (per style, per usergroup, etc.)

digitalpoint 10-09-2011 05:50 AM

An example of the sort of thing you could do with the new hook location...

On digitalpoint.com, premium members can see the "true country" of a poster... I extended it a bit so premium members show the flag of the country the thread starter is in. I made it so the flag only shows when you mouseover the thread (that way it's normally hidden so it's not too obnoxious).

https://vborg.vbsupport.ru/external/2011/10/66.png

Juggernaut 10-09-2011 06:38 AM

Quote:

Originally Posted by digitalpoint (Post 2255002)
An example of the sort of thing you could do with the new hook location...

On digitalpoint.com, premium members can see the "true country" of a poster... I extended it a bit so premium members show the flag of the country the thread starter is in. I made it so the flag only shows when you mouseover the thread (that way it's normally hidden so it's not too obnoxious).

https://vborg.vbsupport.ru/external/2011/10/66.png

That's awesome :eek:

alfanexus 10-09-2011 06:56 AM

When this plugin is enabled it sometimes courses an error on search results. To make sure that its not just on my test site it happens, I testet this on digitalpoint.

http://forums.digitalpoint.com/searc...4927464&page=3 searched for "service" and got the following error on page 3:
Warning: array_merge() [function.array-merge]: Argument #2 is not an array in [path]/packages/vbforum/search/result/thread.php(194) : eval()'d code on line 10

Another search for "rebel" page 14 (http://forums.digitalpoint.com/searc...927528&page=14)


It dosent happen that often on your site, its more frequent on my internal testsite.

digitalpoint 10-09-2011 07:03 AM

Hmmm... yeah, that could happen if search results returns a thread that was created by a user that no longer exists. If you open the plug-in at the search_results_threadbit location, change this:

PHP Code:

$thread array_merge($thread$avatar_info); 

to this:
PHP Code:

$thread array_merge($thread, (array)$avatar_info); 

I made the change to our dev version, so will be part of next version.

alfanexus 10-09-2011 07:13 AM

wow you are fast :) works perfectly, thanks!

nacaruncr 10-09-2011 10:33 AM

Who I can change in the mini-avatar the title say "Thread description...." for the username of the mini-avatar??

excuse me my english :S

cykelmyggen 10-09-2011 11:16 AM

Installed - working perfect - nominated for MOTM :)

grey_goose 10-09-2011 12:50 PM

This is beautiful and amazing -- thank you so much. Nom'd.

Mostjolly 10-10-2011 01:22 AM

1 Attachment(s)
Hey Shawn,

Thanks for sharing this fantastic hack, is it possible you can add the rounded border effect avatar for "Postbit" template, I've attached the attachment, hopefully it'll give you an idea of what I'm talking about.

Nhat :D

digitalpoint 10-10-2011 01:30 AM

That would really just be a CSS entry. Add this to your additional.css template and it should work...

Code:

.postbit .postuseravatarlink img {
        padding: 5px;
        border: 5px solid blue;
        border-radius: 15px;
}

Obviously replace the blue color with whatever you want.

Mostjolly 10-10-2011 01:48 AM

1 Attachment(s)
Thanks that was easy,

Also are you planning to integrate the exact functionality for the "Forumhome" page listing? (see attachment)

Hmmm.. and for a more advanced developments, I was thinking you could use this same feature for the "Quote" functionality, so basically when I quoted you.. you'd see a little avatar of me at the top bottom right of your avatar.. it's pretty sweet knowing who you're/they're directly communicating to ;)

Nhat

digitalpoint 10-10-2011 04:57 AM

Quote:

Originally Posted by Mostjolly (Post 2255354)
Thanks that was easy,

Also are you planning to integrate the exact functionality for the "Forumhome" page listing? (see attachment)

Hmmm.. and for a more advanced developments, I was thinking you could use this same feature for the "Quote" functionality, so basically when I quoted you.. you'd see a little avatar of me at the top bottom right of your avatar.. it's pretty sweet knowing who you're/they're directly communicating to ;)

Nhat

No, there are no plans to do something similar to the forumhome page or add avatars to quotes.

Skyrider 10-10-2011 05:12 AM

Quote:

Originally Posted by digitalpoint (Post 2254928)
Since I'm sure someone will ask how to make a custom setting that users can use to disable Thread Avatars just for themselves, you can go to AdminCP -> User Profile Fields -> Add New User Profile Field

Choose the "Single Selection Radio Buttons" option. These are the settings I use for digitalpoint.com:

https://vborg.vbsupport.ru/external/2011/10/60.png

An important thing to note is what the internal field ID is for your new setting. In my case it's 21... so in the plug-in, we are reading field21.

Create a new plug-in like so (do NOT pick the Thread Avatars as the product since it would get overwritten on an update):

https://vborg.vbsupport.ru/external/2011/10/61.png

You now should have a setting that users can set in their UserCP settings that allows them to toggle Thread Avatars on/off.

You can use a similar plug-in to set the $show['hide_thread_avatars'] variable to "true" for other things if you want (per style, per usergroup, etc.)

While I really appreciate you adding the code, would have been great if you copy/paste the code so I can be sure I'm doing it right rather than typing it all over. So far, I've done this:

Code:

if ($vbulletin->userinfo['field28'] == 'yes') $show['hide_thread_avatars'] = true;
However, this doesn't seem to work. I've set it to NO in the options menu (on my profile) and yet it still shows up. And yes, I've updated the product. And yes, the field is also correct. Also, I selected the cache_templates. I've done everything and copied everything from your images above, still doesn't work.

digitalpoint 10-10-2011 07:10 AM

THat *should* be it assuming field28 is being set to 'Yes' for your account.

You can double check by going into phpmyadmin (if you have it installed), going into the userfield table, and checking the record for your userid. Make sure there are no leading/trailing spaces in there.

MrD 10-10-2011 07:28 AM

Hi,
works fine in FF but in IE 8 there is no transparency :(

digitalpoint 10-10-2011 07:55 AM

The opacity will work in the latest version of IE, but for old versions, if you want it to work, you can go into your dpta.css template and change this:

Code:

.threadbit .icon {
        opacity:0.6;
}

.threadbit.new .icon {
        opacity:1;
}

to this:
Code:

.threadbit .icon {
        opacity:0.6;
        filter:alpha(opacity=60);
}

.threadbit.new .icon {
        opacity:1;
        filter:alpha(opacity=100);
}

I stopped writing code for old versions of IE. If the user doesn't want to (or can't upgrade to IE), and they also don't want to use a browser that works properly with CSS standards, then ultimately it's their choice.

That being said, if you (personally) want to support old versions of IE, that code will do it. :)

MrD 10-10-2011 08:24 AM

1 Attachment(s)
Hi,
thanks.
But what is the Definition of older IE Version ?
I mean, IE 8 is not Old :D

But i have one thing.
If DPTA is activ there displayed me one Thread in Searchresults wit no entry ?

Attachment 133650

Maybe a Idee for Future updates.
If the Icon Legend under the Threadlist would be updatet with Threadavatars it shows Great :D
Maybe as Example with the no Avatar icon :D

digitalpoint 10-10-2011 08:36 AM

Quote:

Originally Posted by MrD (Post 2255477)
Hi,
thanks.
But what is the Definition of older IE Version ?
I mean, IE 8 is not Old :D

But i have one thing.
If DPTA is activ there displayed me one Thread in Searchresults wit no entry ?

Attachment 133650

As far as IE goes, anything older than IE9 is what I consider "old". Not necessarily because of it's age, but because it's a terrible browser. The way I figure it is this... if I code something and it works perfect in Firefox, Chrome, Safari and Opera, but not perfectly in IE, then the issue is most likely a problem with IE (in this case old versions of IE not supporting standard CSS), not my code. That being said... IE9 is a pretty good browser. My logic is this... If a user makes the choice to use a browser that sucks, it's ultimately up to them. I'm not going to force a good browsing experience upon them when they consciously choose to not have one. :) At least that's my logic for digitalpoint.com. But since other people may not share my logic, I rolled the extra CSS into 1.0.4 for you.

As far as search results go, it looks like you may have hit this issue (also fixed in 1.0.4 already in the source)... When a thread was created by a user that no longer exists in the user table (the fix is here).

digitalpoint 10-10-2011 08:55 AM

Updated the download to 1.0.4... the only changes are the CSS for old versions of Internet Explorer, and the issue when search returns a thread created by a non-existant user.

abdobasha2004 10-10-2011 10:18 AM

nice idea
and welcome back Shawn...

smaacom 10-10-2011 12:10 PM

great product ... thanks .

for rtl language forum you have to change from "left" to "right" : ( in red )

Code:

.threadbit img.self {
        max-width:14px;
        max-height:14px;
        background-color:#ddd;
        border:1px solid #555;
        padding:1px;
        border-radius:2px;
        position:absolute;
        top:{vb:math {vb:stylevar threadbit_iconsize.width}-14}px;
        right:{vb:math {vb:stylevar threadbit_iconsize.width}-8}px;
        box-shadow:0 0 1px #eee;
        -webkit-box-shadow:0 0 1px #eee;
}


Code:

.threadbit.lock .lockicon {
        position:absolute;
        top:2px;
        right:7px;
        width:20px;
        height:20px;


Code:

.threadbit .threadstatus.avatars div.overlay {
        position:absolute;
        top:2px;
        right:2px;
        width:32px;
        height:32px;


MrD 10-10-2011 03:51 PM

Hi,
thx for Fixing :D

nCODE 10-10-2011 05:26 PM

I love you man!!! :D
(though I am not a gay ;) )

Brandon Sheley 10-10-2011 07:20 PM

nice xenforo look :)
I like it
thanks for sharing

digitalpoint 10-10-2011 08:03 PM

Quote:

Originally Posted by Brandon Sheley (Post 2255682)
nice xenforo look :)

Yep... which I mentioned here: http://products.digitalpoint.com/vbu...ad-avatars.php

nacaruncr 10-11-2011 04:39 PM

Quote:

Originally Posted by nacaruncr (Post 2255062)
Who I can change in the mini-avatar the title say "Thread description...." for the username of the mini-avatar??

excuse me my english :S

anyone???

digitalpoint 10-11-2011 06:27 PM

Quote:

Originally Posted by nacaruncr (Post 2255964)
anyone???

You could probably do it with a template edit... It's nothing we add or change with this plug-in though, so if you want the hover to read something different than it does without the plug-in, you would need to edit a template (I presume).

hugh_ 10-11-2011 07:21 PM

Great mod, thanks! Would it be possible to make the avatar size configurable? The cropped versions don't look so hot...

digitalpoint 10-11-2011 08:22 PM

It keys on the threadbit_iconsize StyleVar (specifically the width) for it. It doesn't use the height because it just keeps it square.

And I'll be completely honest, I haven't tested altering it to make it larger or smaller, but it *should* work in theory. :)

hugh_ 10-11-2011 09:47 PM

That works nicely, thanks! :)

digitalpoint 10-11-2011 10:03 PM

Quote:

Originally Posted by hugh_ (Post 2256062)
That works nicely, thanks! :)

What's your website? Mind if I take a look at how it looks with an alternate size?


All times are GMT. The time now is 04:27 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01625 seconds
  • Memory Usage 1,851KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (7)bbcode_code_printable
  • (2)bbcode_php_printable
  • (14)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete