vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Question about GPC vars (https://vborg.vbsupport.ru/showthread.php?t=197296)

Antivirus 11-26-2008 02:28 PM

Question about GPC vars
 
I've noticed that vbulletin has the ability to recognize certain sincle character arguments in GPC when cleaning vars such as c=calendarid, e=eventid, f=forumid, etc... thus allowing a $_REQUEST to look like this:
https://vborg.vbsupport.ru/newthread...newthread&f=15

as opposed to this:
https://vborg.vbsupport.ru/newthread...ead&forumid=15

I've looked all over for the "key" to this, but can't find it. Somewhere there has to be a array of keys=>values for f=>forumid, c=>calendarid, etc...

Does anyone know where this is located?

Lynne 11-26-2008 03:01 PM

/includes/class_core.php

How do some of you guys get by without a text editor that does a search for a word in a folder? I couldn't possible code if I couldn't search the vb folder for certain functions or pieces of code.

Guest190829 11-26-2008 03:05 PM

It's located in includes/class_core.php within the actual input cleaner class, var $shortvars if I remember correctly.

Antivirus 11-26-2008 03:11 PM

ah yes, i see it now, thanks!

posting here for quick reference for others:
PHP Code:

    /**
    * Translation table for short name to long name
    *
    * @var    array
    */
    
var $shortvars = array(
        
'f'     => 'forumid',
        
't'     => 'threadid',
        
'p'     => 'postid',
        
'u'     => 'userid',
        
'a'     => 'announcementid',
        
'c'     => 'calendarid',
        
'e'     => 'eventid',
        
'q'        => 'query',
        
'pp'    => 'perpage',
        
'page'  => 'pagenumber',
        
'sort'  => 'sortfield',
        
'order' => 'sortorder',
    ); 



All times are GMT. The time now is 08:24 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.00962 seconds
  • Memory Usage 1,729KB
  • 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
  • (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