vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   How do I do this? :P (https://vborg.vbsupport.ru/showthread.php?t=178478)

CampinCarl 05-08-2008 12:24 AM

How do I do this? :P
 
I have a custom profile field, and people keep incorrectly entering the information that needs to go in it, so i just need to know how to make it so the information they enter has to begin with the correct phrase
What I need it for: I have a custom field for someones steam ID, so they can enter their steam id, and they keep entering their steam name, so intstead of getting STEAM:0:0:1234567, im gettin stuff like "johnfrink", so i need to make it so whatever you enter has to start with STEAM:, :P

thanks

Marco van Herwaarden 05-08-2008 11:57 AM

You can use the "Regular Expression" field in the Custom Profile Field to validate the input.

anuanu 08-24-2008 12:21 PM

Same issue with me, I tried to understand how to do the regular expressions but i was completly confused.

Could you give me info to put into the field?

Dismounted 08-24-2008 01:23 PM

Regular Expressions are daunting, I agree. But it is very, very useful. I use this site as a reference.

anuanu 08-24-2008 04:03 PM

From that site you gave me i was still confused but I played with the program "RegexBuddy" and i think I might have figured out the code i need but im not sure as im trying to test it out now.

the code:

steam_[0-9]:[0-9]:[0-9]*+

EDIT: i dont know how to prevent digits the repeat more then 4 times though

Dismounted 08-25-2008 10:38 AM

The "formula" for a SteamID is: STEAM_X:Y:Z. Where X is an unsigned 8-bit value, Y is an unsigned 4-bit value and Z is an unsigned 32-bit value.
Code:

^(?-i)(STEAM_[0-9]{1,3}:[0-9]{1,2}:[0-9]{1,10})$
This expressions checks for length, but does not check actual value (ie. making sure value is 4-bit, etc.).

Videx 08-25-2008 11:46 PM

People actually give you their Steam IDs???

ssslippy 08-26-2008 12:26 AM

Steam ID's cant be exploited in anyway but its a great way for people to link accounts to server information. I have been on servers that fully integrate their forum accounts into the game.


All times are GMT. The time now is 04:59 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.00957 seconds
  • Memory Usage 1,720KB
  • 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
  • (8)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