vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   $vbulletin->GPC (https://vborg.vbsupport.ru/showthread.php?t=175224)

dayzman 04-05-2008 02:53 PM

$vbulletin->GPC
 
Hi,

Does anyone know which function puts values into the $vbulletin->GPC array, i.e. the actual initialisation of the array. Thanks.

Michael

Opserty 04-05-2008 03:10 PM

It stores cleaned input which has been passed through the vBulletin Input Cleaner.

Using the vBulletin Input Cleaner

What are you trying to do?

effeff70 01-15-2018 07:35 PM

Even though this thread is quite old:
I am looking for an answer to dayzman's question. Why?
vbulletin preselects a certain value within certain dropdown boxes. For instancem when registering at a forum, within the 'showbirthday' dropdown list, the entry with value="2" is preselected.
This is a privacy concern! I would like to change this to the entry with value="0" being shown. Within register.php I found:
$sbselected = array($vbulletin->GPC['showbirthday'] => 'selected="selected"');
I concluded that the values I am looking for are to be found in the GPC Array. Well, that's where I am stuck and I would appreciate help with this.

Thanks.

Dave 01-15-2018 09:31 PM

The $vbulletin->GPC array contains all user input data that has been passed through the input "cleaner". ($_POST, $_GET, $_COOKIE) You sure you don't just want to make a template modification to change the default value of the showbirthday option?

effeff70 01-16-2018 07:50 PM

I wasn't sure how chaging the template could possibly effect other functionallity (I am not a VB pro as you can tell by my question).
And since the values of the listbox is not a user input I thought...

Anyways: Enough on problems, let's focus on solutions! ;)
Where and how would I have to change which template in order to achieve a different pre-selection within the 'showbirthday' listbox?

Dave 01-16-2018 08:23 PM

It would probably be easier for you to modify the register.php file.
Look for the following in register.php:
PHP Code:

        // Default Birthday Privacy option to show all
        
if (empty($errorlist))
        {
            
$sbselected = array(=> 'selected="selected"');
        } 

And change that 2 to 0.

effeff70 01-17-2018 06:25 AM

...it's so simple when you know what to look for! ;-)
Thanks for your help.


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