Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Military Branches Details »»
Military Branches
Version: 1.01, by SVTCobraLTD SVTCobraLTD is offline
Developer Last Online: Nov 2023 Show Printable Version Email this Page

Category: Profile Enhancements - Version: 4.1.0 Rating:
Released: 01-04-2011 Last Update: Never Installs: 9
Template Edits
 
No support by the author.

Military Branches v1.01
Created by SVTCobraLTD for vb4
Instructions for vb4 by BirdsOPrey5


This will add a small Military Banner to your postbit templates. I found this useful for my forums so I hope you do. See the screen shots for more information. Right now it only contains Army, Navy, Marines and Air Force. Currently the images are made with a white background and a dark gray background. I am willing to help make the images match the background on your board for members who donate.

UPLOAD FILES
ADD USER GROUPS
TEMPLATE EDITS
ENJOY!!

Do not forget to Mark as Installed

Download Now

File Type: zip MilitaryBranches1.01.zip (47.5 KB, 101 views)

Screenshots

File Type: gif screen1.gif (7.0 KB, 0 views)
File Type: gif screen2.gif (7.4 KB, 0 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Благодарность от:
trackpads

Comments
  #2  
Old 01-05-2011, 09:45 PM
ThisIrksMe ThisIrksMe is offline
 
Join Date: Dec 2010
Posts: 7
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can you create branch of service with Veteran tags such as Marine Corps Veteran or USMC Veteran, etc? Even Operation Enduring/Iraqi Freedom tags? Don't forget National Guard and Reserves. Did you know that 70% of the US deployed troops are Reserves & National Guard. Just suggestions if you decide to create an update. Ooh-Rah and Hooah, thank you for your support!!

SGT Chris Larson
USMC Veteran 1998-2002
US Army National Guard 2008-Present
Reply With Quote
  #3  
Old 01-05-2011, 10:16 PM
Dr.osamA's Avatar
Dr.osamA Dr.osamA is offline
 
Join Date: Aug 2004
Location: Syrie
Posts: 979
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not every one in the U.S. Army
And not every one is interested in the U.S. Army
You can modify the MOD to work, according to their works, doctor,teacher accountant engineer etc etc.

somthing like this MOD
https://vborg.vbsupport.ru/showthread.php?t=229540

but for jops
This is only my suggestion

thank you
Reply With Quote
  #4  
Old 01-06-2011, 04:49 PM
ThisIrksMe ThisIrksMe is offline
 
Join Date: Dec 2010
Posts: 7
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I cant get this to work. I used the .GIF file in Welshy's Country Flags Code and the picture wasn't coming up. Got any ideas?
Reply With Quote
  #5  
Old 01-06-2011, 05:47 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Are you getting a broken image placeholder or nothing at all? Are you trying it in both the postbit and profile?
Reply With Quote
  #6  
Old 01-18-2011, 12:35 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I had a mistake in the code... if you followed the instructions posted please change the line:

Code:
<vb:if condition="$vbulletin->userinfo[usergroupid] == 6"><img src="http://www.qapla.com/ju/jump.gif" /><br /></vb:if>
to

Code:
<vb:if condition="$userinfo[usergroupid] == 6"><img src="http://www.qapla.com/ju/jump.gif" /><br /></vb:if>
Reply With Quote
  #7  
Old 06-29-2011, 02:10 PM
jimnyc jimnyc is offline
 
Join Date: Aug 2003
Location: New York
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have added this code to my forum but am having a little trouble. I got it to work fine by "changing" a users usergroup, but ran into too many problems with prior permissions and such. I then went to use the additional usergroup option and cannot get it to work. My new forum ID's are 17,18,19,20 - can someone see what I possibly did wrong here? (I suck with coding!)

Code:
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 17)"><img src="images/misc/army_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 18)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 19)"><img src="images/misc/marine_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 20)"><img src="images/misc/navy_white.gif" border="0" alt="" /></vb:if>
Reply With Quote
  #8  
Old 06-29-2011, 02:40 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by jimnyc View Post
I have added this code to my forum but am having a little trouble. I got it to work fine by "changing" a users usergroup, but ran into too many problems with prior permissions and such. I then went to use the additional usergroup option and cannot get it to work. My new forum ID's are 17,18,19,20 - can someone see what I possibly did wrong here? (I suck with coding!)

Code:
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 17)"><img src="images/misc/army_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 18)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 19)"><img src="images/misc/marine_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="in_array($post[usergroupid], array(17,18,19,20) && is_member_of($post, 20)"><img src="images/misc/navy_white.gif" border="0" alt="" /></vb:if>
If you want to use secondary usergroups it's a different condition.

Change:

Code:
in_array($post[usergroupid], array(17,18,19,20)
to:

Code:
is_member_of($post, 17,18,19,20)
So a line would be:
Code:
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
Reply With Quote
  #9  
Old 06-29-2011, 02:48 PM
jimnyc jimnyc is offline
 
Join Date: Aug 2003
Location: New York
Posts: 70
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks so much!! I added the following code, but all 4 images appear for a member that is only added to the "army" usergroup which is number 17.

Code:
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/army_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/marine_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/navy_white.gif" border="0" alt="" /></vb:if>
Reply With Quote
  #10  
Old 06-29-2011, 02:51 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by jimnyc View Post
Thanks so much!! I added the following code, but all 4 images appear for a member that is only added to the "army" usergroup which is number 17.

Code:
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/army_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/marine_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17,18,19,20)"><img src="images/misc/navy_white.gif" border="0" alt="" /></vb:if>

I don'r know which group corresponds to what but it looks like you want:

Code:
<vb:if condition="is_member_of($post, 18)"><img src="images/misc/airforce_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 17)"><img src="images/misc/army_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 19)"><img src="images/misc/marine_white.gif" border="0" alt="" /></vb:if>
<vb:if condition="is_member_of($post, 20)"><img src="images/misc/navy_white.gif" border="0" alt="" /></vb:if>
Change the numbers to the corresponding branch. (17 is army, etc...)
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:53 PM.


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.11433 seconds
  • Memory Usage 2,344KB
  • Queries Executed 26 (?)
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
  • (10)bbcode_code
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (1)post_thanks_box_bit
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (3)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)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_postinfo_query
  • fetch_postinfo
  • 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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete