Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
YouTube Video Avatars for specified usergroups Details »»
YouTube Video Avatars for specified usergroups
Version: 1.00, by 4x4 Mecca 4x4 Mecca is offline
Developer Last Online: Jun 2013 Show Printable Version Email this Page

Category: Show Thread Enhancements - Version: 3.6.4 Rating:
Released: 06-24-2007 Last Update: 06-24-2007 Installs: 100
Template Edits
Is in Beta Stage  
No support by the author.

Hello, what this mod does is allows users to have a "Video Avatar" if they are a member of the usergroup you specify.

Installation instructions are attached. See screen shots below to get an idea of what it looks like.

UPDATE! I recorded a video of me installing it on a blank board. The video should help anyone having trouble. There are a couple extra things like me closing my password manager that you should ignore, but the video will show you what to do.

Installation Video Instructions

You can change the height and width of the video by changing the attributes in the code.

It requires one template edit, 2 if you use both postbit styles.
It requires one profile field.

I am new to the modding still, and my instructions here aren't great, but you can see it in action here.

UPDATE!
To Display them in your user profiles
open the memberinfo template
find
Code:
			<if condition="$show['avatar']">
				<td><img src="$userinfo[avatarurl]" $userinfo[avatarsize] alt="<phrase 1="$userinfo[username]">$vbphrase[xs_avatar]</phrase>" border="0" style="border:1px solid $stylevar[tborder_bgcolor]; border-top:none" /></td>
			<else />
				<td>&nbsp;</td>
			</if>
Replace with
Code:
<if condition="in_array($post['usergroupid'], array(5,6,7,12,14)) AND $post[fieldXX]">
<td>
<object width="150" height="123.5"><param name="movie" value="http://www.youtube.com/v/$post[fieldXX]"></param><param name="wmode" value="transparent"></param><embed src="http://www.youtube.com/v/$post[fieldXX]" type="application/x-shockwave-flash" wmode="transparent" width="150" height="123.5"></embed></object>
</td>
<else />	
			<if condition="$show['avatar']">
				<td><img src="$userinfo[avatarurl]" $userinfo[avatarsize] alt="<phrase 1="$userinfo[username]">$vbphrase[xs_avatar]</phrase>" border="0" style="border:1px solid $stylevar[tborder_bgcolor]; border-top:none" /></td>
			<else />
				<td>&nbsp;</td>
			</if>
			</if>
</if>
Be sure you replace all fieldXX with your actual field number!

Click installed!
Nominate for MOTM!

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 06-25-2007, 10:30 PM
4x4 Mecca 4x4 Mecca is offline
 
Join Date: Feb 2007
Posts: 396
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Glad it works for you TheBlackPoet. If the people who are having trouble could post their postbit file, I can see why it's not working.
Reply With Quote
  #13  
Old 06-26-2007, 12:28 AM
Silvio's Avatar
Silvio Silvio is offline
 
Join Date: Nov 2005
Location: Italy
Posts: 140
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

gorgeous:P
I will install it right now


ty for sharing this good idea/work
Reply With Quote
  #14  
Old 06-26-2007, 01:45 AM
rjmjr69's Avatar
rjmjr69 rjmjr69 is offline
 
Join Date: Jan 2007
Location: Southie
Posts: 876
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Anyone here?
Reply With Quote
  #15  
Old 06-26-2007, 01:54 AM
4x4 Mecca 4x4 Mecca is offline
 
Join Date: Feb 2007
Posts: 396
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Did you see my reply. I asked you to post your postbit template.
Reply With Quote
  #16  
Old 06-26-2007, 08:00 AM
PoetJA-1975's Avatar
PoetJA-1975 PoetJA-1975 is offline
 
Join Date: Sep 2006
Location: Meh...
Posts: 1,218
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Postbit below 4x4 Mecca - thanx very much
Question: Would make a difference in the code if you have default avatar selected to show?
Thanx again -

Jacquii.

Quote:
<!-- user info -->
<table cellpadding="0" cellspacing="$stylevar[cellpadding]" border="0" width="100%">
<tr>
<if condition="$show['avatar']">
<!-- check for staff -->
<if condition="in_array($post[usergroupid], array(5,6,7))">
<!-- I am staff so do this -->
<td class="alt2">

<table cellpadding="4" cellspacing="0" border="0" width="190" height="120" align="center" background="images/$post[username]_avatar.gif" nowrap="nowrap" no-repeat>
<tr>
<td width="46%">&nbsp;</td>
<td><img src="$post[avatarurl]" height="70" width="70" align="center"></td>
</tr>
</table>
</td>
<else />
<!-- I am not staff so do this -->
<td class="alt2">
<a href="member.php?$session[sessionurl]u=$post[userid]"><img src="$post[avatarurl]" $post[avwidth] $post[avheight] alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a>
</td>
</if>
</if>
<td nowrap="nowrap">
<fieldset class="fieldset">
<legend><font face="Arial Black">Member Information</font></legend>
<div id="postmenu_$post[postid]">
<if condition="$show['profile']">
<a class="bigusername" href="member.php?$session[sessionurl]u=$post[userid]">$post[musername]</a>
$post[onlinestatus]
<script type="text/javascript"> vbmenu_register("postmenu_$post[postid]", true); </script>
<else />
$post[musername]
</if>
</div>
<if condition="$post[field9] != ''"><div class="smallfont">
Real Name: <strong>$post[field9]</strong>
</div></if>
<if condition="$post['usertitle']"><div class="smallfont">$post[usertitle]</div></if>
<if condition="$post['rank']"><div class="smallfont" align="center">$post[rank]</div></if>
<if condition="!empty($post[mood])">
<div class="smallfont" align="center">
$vbphrase[my_mood]: <img src="images/mood/$post[mood].gif" border="0" />
</if></div>

<if condition="$thread[postusername]==$post[username]"><div class="smallfont" align="center">
<img src="$stylevar[imgdir_misc]/tstarter.gif" alt="This Member Is The Original Thread Starter" border="0" /></div>
</if></fieldset>
</td>
<td width="100%">&nbsp;</td>
<td valign="top" nowrap="nowrap">
<div class="smallfont">
$post[crowns]$post[champtext]
<if condition="$post['joindate']"><div>$vbphrase[join_date]: $post[joindate]</div></if>
<if condition="$show['last_seen_online']"><div>$vbphrase[last_seen_online]: $post[lastseen_date] $post[lastseen_time]</div></if>
<if condition="$post['field2']"><div>$vbphrase[location_perm]: $post[field2]</div></if>

<!-- Local Date and Time in Post -->
<if condition="$post[userid]">
<div class="smallfont" align="left">
$vbphrase[bf2_local_time]: $post[localtime]
</div>
</if>
<!-- Local Date and Time in Post -->

<div>
$vbphrase[posts]: <a href="search.php?$session[sessionurl]do=finduser&amp;u=$post[userid]" rel="nofollow">$post[posts]</a> $vbphrase[threads]: <a href="search.php?$session[sessionurl]do=process&amp;showposts=0&amp;starteronly=1&amp;e xactname=1&amp;searchuser=$post[username]" rel="nofollow">$post[threads]</a>
</div>
<div class="smallfont">
<if condition="$post['age']">$vbphrase[age]: <if condition="$show[member]">$post[age]<else />$vbphrase[peterska2_private]</if></if> </if> <if condition="$post['zodiac_sign']">$post[zodiac_sign]</if><if condition="$post[field8]">$vbphrase[gender] <img src="$stylevar[imgdir_misc]/$post[field8].gif" alt="$post[field8]" />
<if condition="$post[field6] != ''">
Country: <img src="images/flags/$post[field6].gif" title="$post[field6]" align="center">
</div></if>
<div class="smallfont">
<if condition="$show['reppower']">
<div>$vbphrase[reppower]: <span id="reppower_$post[postid]_$post[userid]">$post[reppower] @ $post[reputation]</span></div>
</if>
<if condition="$show['reputation']">
<div style="padding-bottom:2px"><span id="repdisplay_$post[postid]_$post[userid]">$post[reputationdisplay]</span></div>
</if>
</div>
<div><if condition="$show[member]">$post[icqicon] $post[aimicon] $post[msnicon] $post[yahooicon] $post[skypeicon] <if condition="$show['homepage']"><a href="$post[homepage]" target="_blank" dir="ltr"><img src="images/misc/userhome.gif" alt="Member's Website" border="0" /></a></if><if condition="$post[field11]">
<!-- Myspace button -->
<a href="http://www.myspace.com/$post[field11]" target="_blank">
<img src="images/misc/myspace.png" border="0" title="View My MySpace"></a>
<!-- / Myspace button -->
</if><else />$vbphrase[peterska2_im_is_private]</if>

</if></div>
<!-- show awards -->
<if condition="$post[showuserawards]">
<fieldset><legend><a href="member.php?u=$post[userid]#award" title="$vbphrase[more_awards]">$vbphrase[award_showcase]</a></legend>
<div>
$post[userawards]
<br>
<a href="member.php?u=$post[userid]#award" title="$vbphrase[more_awards]">$vbphrase[total_awards]</a>: $post[num_awards]
</div>
<if condition="$show['iprof_rating']">
<div>
<if condition="$show['who_rated_member']"><a href="#" onclick="who_rated_member($post[userid]); return false;">$vbphrase[iprof_rating]</a><else />$vbphrase[iprof_rating]</if>:
<a href="$vboptions[bburl]/member.php?$session[sessionurl]u=$post[userid]&amp;nojs=1#goto_memberrating" title="<phrase 1="$post[iprof_votenum]" 2="$post[iprof_voteavg]">$vbphrase[iprof_user_rating_x_votes_y_average]</phrase>"><if condition="$post['iprof_rating']"><img class="inlineimg" src="$stylevar[imgdir_rating]/rating_$post[iprof_rating].gif" border="0" alt="<phrase 1="$post[iprof_votenum]" 2="$post[iprof_voteavg]">$vbphrase[iprof_user_rating_x_votes_y_average]</phrase>" /><else />$vbphrase[iprof_not_rated]</if></a>
</div>
</if>

</fieldset>
</if>
<!-- /show awards -->


<if condition="$show['infraction']">
<div class="smallfont" padding-top:2px">
$vbphrase[infractions]: $post[warnings]/$post[infractions] ($post[ipoints])</div>
</div>
</if>
</td>
</tr>
</table>
<!-- / user info -->
Reply With Quote
  #17  
Old 06-26-2007, 10:30 AM
tipoboy's Avatar
tipoboy tipoboy is offline
 
Join Date: Dec 2005
Location: scotland
Posts: 693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i got it working thanks for a great mod!!

1 problem i change the array values for a custom usergroup called video avatars (field 13) i only want this usergroup to have video avatars.

the problem i get is when i add myself as a secondary user to that group the video avatar doesnt work is there some special priviledges you need to use when making the usergroup?? i just based it on the registered users group!!

do you follow what i am saying?
your help would be appreciated
dave
Reply With Quote
  #18  
Old 06-26-2007, 11:05 AM
tipoboy's Avatar
tipoboy tipoboy is offline
 
Join Date: Dec 2005
Location: scotland
Posts: 693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

also any way of making the video avatars show on all the sections where the avatar's arefo example vbadvanced ortal user cp etc etc

so if you are in the usergroup for video avatars all instances of your avatar become the video avatar not just the postbit/postbit_legacy

thanks again
dave
Reply With Quote
  #19  
Old 06-26-2007, 11:16 AM
Rickeo's Avatar
Rickeo Rickeo is offline
 
Join Date: Jan 2007
Location: Manchester
Posts: 275
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

AMAZING thank you so much
Reply With Quote
  #20  
Old 06-26-2007, 11:19 AM
GuaRRand GuaRRand is offline
 
Join Date: Oct 2005
Posts: 337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

am i the only one who cant get it to work?

I did what the instructions said, editted both postbit's and made the extra profile field, but i dont see it in my UserCP -> edit options or edit avatar...
Reply With Quote
  #21  
Old 06-26-2007, 11:23 AM
GuaRRand GuaRRand is offline
 
Join Date: Oct 2005
Posts: 337
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nvm, got it
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:42 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.13251 seconds
  • Memory Usage 2,324KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete