vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Ok, I know this is a simple mistake.... (https://vborg.vbsupport.ru/showthread.php?t=214398)

HMBeaty 05-23-2009 10:02 PM

Ok, I know this is a simple mistake....
 
I know this is a simple mistake but I haven't coded anything with <else /> in a long time.

If you can tell by the code here:
HTML Code:

<if condition="$bbuserinfo['field11']">
 <dt class="shade">$vbphrase[usml_myspace]</dt>
  <dd><a href="http://www.myspace.com/$userinfo[field11]" target="_blank">$userinfo[field11]</a></dd>
  <else />
  <dd>This user has not entered his MySpace Friend ID</dd>
 </if>

I'm trying to display the users MySpace Profile ID, which I got that down, BUT, if they don't, I want it to display the "This user has not entered his MySpace Friend ID". But I can't get that working right. What am I doing wrong? lol

Lynne 05-23-2009 10:03 PM

You can't have a <dd> tag without a <dt> tag.

HMBeaty 05-23-2009 10:06 PM

So then I would change to this?
HTML Code:

<if condition="$bbuserinfo['field11']">
 <dt class="shade">$vbphrase[usml_myspace]</dt>
  <dd><a href="http://www.myspace.com/$userinfo[field11]" target="_blank">$userinfo[field11]</a></dd>
  <else />
 <dt class="shade">$vbphrase[usml_myspace]</dt>
  <dd>This user has not entered his MySpace Friend ID</dd>
 </if>

Sorry, never used <dd> or <dt> tags before either. vBulletin is throwing in some new stuff on me lol

Lynne 05-23-2009 10:52 PM

That looks like it would work.... However, where are you displaying this? $bbuserinfo is the user viewing the page. If you are doing this on the profile page, you probably want to use $userinfo to display info about the user who's profile you are viewing. (You have $bbuserinfo in one place and $userinfo in another.)

HMBeaty 05-23-2009 11:01 PM

That is in the Memberinfo "Contact Info" tab.

I was guessing it was $userinfo too, we'll see if that works

--------------- Added [DATE]1243123408[/DATE] at [TIME]1243123408[/TIME] ---------------

Ok, that worked. I knew it was a simple mistake


All times are GMT. The time now is 10: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.05084 seconds
  • Memory Usage 1,726KB
  • 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
  • (2)bbcode_html_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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