vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Need Help with Force Required Custom Profile Field (https://vborg.vbsupport.ru/showthread.php?t=258808)

evenmonkeys 02-13-2011 07:19 AM

Need Help with Force Required Custom Profile Field
 
So when you set "Field Required" to "Yes, Always" and when you set "Field Editable by User" to "Yes" it would normally force all members of the site to fill out that information first before they can do anything else. However, I have an exception to this rule that I can't figure out. I'm using a modification that creates a custom page for profile fields. If you read the (?) on "Field Required" it says this:
Quote:

Originally Posted by Field Required
Yes, always - User will be required to complete this field at registration. Enabling this setting will force all users to complete it before they can continue using your forum. This applies only if the field is shown on the "Edit Your Details" page.

Well, it's not on "Edit Your Profile." It's in "Extra Profile." I've been looking through PHP files for two hours and I'm about to cry. I found in "global.php" where it says this:
PHP Code:

// #############################################################################
// check required profile fields
if ($vbulletin->session->vars['profileupdate'] AND THIS_SCRIPT != 'login' AND THIS_SCRIPT != 'profile')
{
    
$vbulletin->options['useforumjump'] = 0;
    eval(
standard_error(fetch_error('updateprofilefields'$vbulletin->session->vars['sessionurl'])));


However.. I can't tell what it's doing. A bit more than I know. Ultimately, it's not forcing members to fill the information out so I figured this is why. So if someone could help me out.. I'd love you forever.

kh99 02-13-2011 01:58 PM

That code you posted shows an error if the user hasn't filled out the required profile fields, if it's not the login or profile page. It looks like $vbulletin->session->vars['profileupdate'] is the flag that says whether profile fields need to be filled in. It looks like that flag is set to 1 in include/functions.php in exec_shut_down().

But I'm not sure I understand your problem - is it showing the error even though your fields shouldn't be required, or do you you want a mod that shows the message even though your field is not on the "Edit Your Profile" page?

evenmonkeys 02-13-2011 10:23 PM

I want a modification that shows the error even if it's not on the "Edit Your Profile" page! That's what I need. When it's checking for people who haven't filled out the information yet, it only checks that one page. I want it to check any page.

evenmonkeys 02-17-2011 12:05 AM

Nothin?


All times are GMT. The time now is 04:47 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.01122 seconds
  • Memory Usage 1,724KB
  • 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)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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