vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Trying to add a custom profile field to "memberaction_dropdown" (https://vborg.vbsupport.ru/showthread.php?t=237685)

grecostimpy 03-07-2010 12:17 AM

Trying to add a custom profile field to "memberaction_dropdown"
 
I'm trying to add a custom profile field to the template "memberaction_dropdown"

Code:

<vb:if condition condition="$post['field5']">
                <li class="left">
                <img src="{vb:stylevar imgdir_siteicons}/profile.png" alt="" />
    Real Name: $post[field5]
                </li>
</vb:if>

I am completely new to VB4, so please bear with me. I also tried it without the if statement and it just renders Real Name: $post[field5] on my website.

I read something about registering variables, but did not quite understand it. Could that be why my custom profile field is not appearing (memberaction_dropdown not having "post" registered?)

Any help is always greatly appreciated.

Thank you.

Edit: Also tried {vb:raw post.field5} with no luck either.

grecostimpy 03-11-2010 04:31 PM

Anyone care to try and tackle this one?

grecostimpy 03-12-2010 11:27 PM

Caaaan you feeeeel the loooove toniiiiight?

Lynne 03-13-2010 01:58 AM

If you look at the template memberaction_dropdown, you'll see the variable being used is memberinfo, not post.

grecostimpy 03-13-2010 11:06 PM

Thank you for your assistance. Variables are something that are going to take some studying as I did not know post and memberinfo are interchangable for custom fields depending on where you are.

Lynne 03-14-2010 03:35 PM

When you perform a query, you usually then assign the results to a variable. The variable name you choose is often associated with where you are going to use it or what it does. So, you need to look at the page to see what the name of the variable is that they are using.


All times are GMT. The time now is 11:17 AM.

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.01106 seconds
  • Memory Usage 1,716KB
  • 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
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (6)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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete