Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 01-14-2003, 10:32 AM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Can someone help me with this hack/feature to my forum?

I want to add two additional info fields into my members profiles to display two things as shown in the attached photo.

The thing thats different is i want them to appear as shown in the pic.

Is that possible? Any help advice appreciated. Willing to pay someone to help me with it as well if possible.
Attached Images
File Type: gif mockup.gif (36.7 KB, 0 views)
Reply With Quote
  #2  
Old 01-14-2003, 10:55 AM
EvilLS1's Avatar
EvilLS1 EvilLS1 is offline
 
Join Date: Apr 2002
Location: Georgia, USA
Posts: 987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If I'm understanding what you want, thats easy. No hack necessary.

Just create the two new fields in your admin control panel.. Make a note of the field IDs for the two new fields. You can find out what the ID is by clicking "modify" under profile fields in the admin control panel, then hold your mouse over the new fields.. The field ID is displayed at the end of the URL at the bottom of your screen. Then edit your postbit template and add this wherever you want them to appear:
<smallfont>Currently Playing: $post[fieldX] <br>
X-Box Live gamer tag: $post[fieldX]<br></smallfont> (replace the Xs with the field ID)

You can add the fancy tables around them with html.
Reply With Quote
  #3  
Old 01-14-2003, 11:07 AM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

awesome. is it ok to prep the code and post it here for you to check for me?
Reply With Quote
  #4  
Old 01-14-2003, 11:26 AM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

what template do i edit?
Reply With Quote
  #5  
Old 01-14-2003, 11:33 AM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

oh and how do i make it NOT appear if nothing is entered into their profile? is that possible?

if you visit http://www.xboxworld.com.au/forum/sh...0844#post40844 you can see it working

what template do i put it into to make it appear under the location and postcount bit?
Reply With Quote
  #6  
Old 01-14-2003, 12:03 PM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

hehe there we go ive got it all working nicely now but if u can help me make it optional so that if nothings entered, nothing displays that would be incredible!
Reply With Quote
  #7  
Old 01-14-2003, 01:48 PM
Craigr's Avatar
Craigr Craigr is offline
 
Join Date: May 2002
Location: Ayr, Scotland
Posts: 194
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by sbryan
oh and how do i make it NOT appear if nothing is entered into their profile? is that possible?

if you visit http://www.xboxworld.com.au/forum/sh...0844#post40844 you can see it working

what template do i put it into to make it appear under the location and postcount bit?
template - postbit

Craig
Reply With Quote
  #8  
Old 01-14-2003, 08:19 PM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks craig, i worked it out can you help mae make it optional, ie make them not display in the forum posts if nothing is entered into the fields by the user..
Reply With Quote
  #9  
Old 01-15-2003, 04:37 AM
EvilLS1's Avatar
EvilLS1 EvilLS1 is offline
 
Join Date: Apr 2002
Location: Georgia, USA
Posts: 987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

In admin/functions.php find:

Code:
if ($post[customtitle]==2) {
			$post[usertitle] = htmlspecialchars($post[usertitle]);
		}
Below it add:

Code:
// first profile field
if ($post[fieldX]!="") {
$gamedata1="<smallfont><b>Currently Playing:</b><br>$post[fieldX]</smallfont><br>";
} else {
$gamedata1="";
}

// second profile field
if ($post[fieldX]!="") {
$gamedata2="<smallfont><b>Xbox Live gamer tag:</b><br>$post[fieldX]</smallfont><br>";
} else {
$gamedata2="";
}
Note: In the code above, replace ALL Xs in "$post[fieldX]" with the field IDs for the two fields you added. There are 4 places that will need to be changed to your field IDs. $gamedata1 is for the first field, and $gamedata2 is for the second.

Now go to your postbit template and remove all of the code & text that you added earlier.. Now replace it with:
$gamedata1
$gamedata2

That should work.
Reply With Quote
  #10  
Old 01-15-2003, 05:56 AM
sbryan's Avatar
sbryan sbryan is offline
 
Join Date: Oct 2002
Location: Melbourne, Australia
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thats awesome, thank you so much EvilLS1, worked perfectly first time!

that is awesome
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 02:16 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.05676 seconds
  • Memory Usage 2,276KB
  • Queries Executed 14 (?)
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
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (1)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
  • 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_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