vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Requests/Questions (Unpaid) (https://vborg.vbsupport.ru/forumdisplay.php?f=112)
-   -   Help with a Seperate Page for Custom Profile Field (https://vborg.vbsupport.ru/showthread.php?t=71886)

Starscream 11-18-2004 01:41 AM

Help with a Seperate Page for Custom Profile Field
 
1 Attachment(s)
I've searched the forums and a couple of people have asked for this hack or one similar to it. Basically, I want to create a seperate page that just shows usernames and a custom profile field - something similar to the memberlist page.

The only difference is, I only want the Username and profile field to show up if someone has filled in that certain profile field.

I've tried a few different approaches to this and none of them have really worked out for me yet. On this attempt I've basically hacked memberlist.php to only show the things I want. Then, I renamed it and uploaded it to my forum - works (pic included below). However, it shows two custom fields (only want 1) and also shows users who didn't fill in the field. I have not modified any of the templates that the memberlist uses (nor do I really want to).

What do I need to do to make the memberlist.php (or renamed file) accomplish my goals? Is it something I can do with just the .php file or do I need to create new templates.

Any help would be much appreciated.

-note: I had a similar post a while back, but I decided to create another post as I'm trying to go in a different direction than before and didn't want to confuse the old coding with this one.

Starscream 11-19-2004 12:15 AM

Wouldn't this hack be just a simple conditional sort of like what's below or is this like a big hack that I need professional (paid) help on?

Something like
PHP Code:

if ($profilefieldX True or whatever 
   Then show 
'Username'
   
else
   
Don't show 'username' or 'profilefield


I didn't think something like this was a big undertaking, but that just may be because of my limited knowledge of php. It's times like these that I wish I knew how to code php.

SVTBlackLight01 11-19-2004 10:40 AM

Here is what the template conditional should look like.

<if condition="$userinfo['fieldX']">
$userinfo[fieldX]
</if>


All times are GMT. The time now is 07:33 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.00933 seconds
  • Memory Usage 1,715KB
  • 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_php_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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