vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   default value in register.php (https://vborg.vbsupport.ru/showthread.php?t=43072)

pank 09-02-2002 05:43 AM

default value in register.php
 
I added a custom user profile field. What I need is for it to have a default value like the "http://" in the homepage area. Since this is a custom user profile field I can't find anywhere that I can set a default value for the input box when a user registers...

I have the "field5" added to the userfield table in the database with a set default value. Problem is when I do that it changes everyone's value in their edit profile. But when a new user signs up it just shows up blank when you go to edit profile...

The area on the register page is the

"Optional Information All information will be viewable by other team forum members."

area. So basically it would be like setting a default value for "biography". Not the one I want to have a default value but it's in the same area of custom user profile fields.

Thanks in advance...

g-force2k2 09-02-2002 07:23 AM

you can edit the field5 value in phpmyadmin and set a default value or you can just drop field5 and readd it using a default value... regards...

g-force2k2

pank 09-02-2002 01:57 PM

Actually I'm using (I think) your avatar as link hack ;) I have the default value set to { images folder}/no_img.gif But, I think what is happening is there is a field when a user signs up. The avatar field. For some reason it is blank and when the user signs up it shoots the blank field over and then it's blank in their edit profile.


I followed the instructions you wrote and it works like a charm, except when I get a new user. I'm using 2.26 by the way. Thanks in advance.

pank 09-02-2002 03:39 PM

Actually I found a way around it. I just went into registeradult, removed the $customfields line.

Then just manually added in an area for the avatar with a default value of my default image path and a name of field5. The bio, occupation does not show up during registration but that's no biggie. It still shows up in Edit Profile. And now when a user signs up it will shoot over the field5 entry and no more broken images as avatars.

Thanks again. If you have a better solution let me know but this one seems to work for now. Thanks again...

** edited **
Hmmm, just found the profilefield in the database with field 5. I think the problem is that there is no default value set in that area. I'm a MySql newb pretty much. Is there a way to just give field 5 a "default" value. That way it should fix the problem without having to hack the templates like I did

Khashyar 08-17-2005 07:34 PM

Hi guys...

I am wondering the same thing... how do you set a default value for a custom user profile field?

Thanks,

Khashyar


All times are GMT. The time now is 04:45 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.00952 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)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