View Single Post
  #1  
Old 01-04-2007, 06:05 PM
h_jinx h_jinx is offline
 
Join Date: Mar 2005
Posts: 19
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default bitfield problems.

I assure you I have searched high and low to a solution to this before I posted. Anyone that can shed light on this would be appreciated.

I have the following:

Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<bitfields product="item_shop">
    <bitfielddefs>
        <group name="ugp">
          <group name="shop_item_settings">
              <bitfield name="shop_invent_size" group="shop_usergroup_options" phrase="shop_inventory_size" intperm="true"  >1</bitfield>
              <bitfield name="shop_pbit_size" group="shop_usergroup_options" phrase="shop_pbit_size" intperm="true" >1</bitfield>
            </group>
        </group>
    </bitfielddefs>
</bitfields>
It appears fine in the usergroup manager. On checking the dbase it updates the fields correctly and after updates the usergroup manager shows these updates to be true. I have also rebuilt the fields a number of times.

However, when I try to access it in code using:

Code:
$visibleallowed = $vbulletin->bf_ugp_shop_item_settings['shop_pbit_size'];
$inventoryallowed = $vbulletin->bf_ugp_shop_item_settings['shop_invent_size'];
I am getting nothing back.

var_dump($vbulletin->bf_ugp_shop_item_settings);

brings back NULL;

var_dump($vbulletin->bf_ugp);

brings back

Code:
array(8) {   ["forumpermissions"]=>   &array(20) {     ["canview"]=>     int(1)     ["canviewthreads"]=>     int(524288)     ["canviewothers"]=>     int(2)     ["cansearch"]=>     int(4)     ["canemail"]=>     int(8)     ["canpostnew"]=>     int(16)     ["canreplyown"]=>     int(32)     ["canreplyothers"]=>     int(64)     ["caneditpost"]=>     int(128)     ["candeletepost"]=>     int(256)     ["candeletethread"]=>     int(512)     ["canopenclose"]=>     int(1024)     ["canmove"]=>     int(2048)     ["cangetattachment"]=>     int(4096)     ["canpostattachment"]=>     int(8192)     ["canpostpoll"]=>     int(16384)     ["canvote"]=>     int(32768)     ["canthreadrate"]=>     int(65536)     ["followforummoderation"]=>     int(131072)     ["canseedelnotice"]=>     int(262144)   }   ["pmpermissions"]=>   &array(3) {     ["canignorequota"]=>     int(4)     ["cantrackpm"]=>     int(1)     ["candenypmreceipts"]=>     int(2)   }   ["calendarpermissions"]=>   &array(6) {     ["canviewcalendar"]=>     int(1)     ["canpostevent"]=>     int(2)     ["caneditevent"]=>     int(4)     ["candeleteevent"]=>     int(8)     ["canviewothersevent"]=>     int(16)     ["isnotmoderated"]=>     int(32)   }   ["wolpermissions"]=>   &array(5) {     ["canwhosonline"]=>     int(1)     ["canwhosonlineip"]=>     int(2)     ["canwhosonlinefull"]=>     int(4)     ["canwhosonlinebad"]=>     int(8)     ["canwhosonlinelocation"]=>     int(16)   }   ["adminpermissions"]=>   &array(17) {     ["ismoderator"]=>     int(1)     ["cancontrolpanel"]=>     int(2)     ["canadminsettings"]=>     int(4)     ["canadminstyles"]=>     int(8)     ["canadminlanguages"]=>     int(16)     ["canadminforums"]=>     int(32)     ["canadminthreads"]=>     int(64)     ["canadmincalendars"]=>     int(128)     ["canadminusers"]=>     int(256)     ["canadminpermissions"]=>     int(512)     ["canadminfaq"]=>     int(1024)     ["canadminimages"]=>     int(2048)     ["canadminbbcodes"]=>     int(4096)     ["canadmincron"]=>     int(8192)     ["canadminmaintain"]=>     int(16384)     ["canadminupgrade"]=>     int(32768)     ["canadminplugins"]=>     int(65536)   }   ["genericpermissions"]=>   &array(30) {     ["canviewmembers"]=>     int(1)     ["canmodifyprofile"]=>     int(2)     ["caninvisible"]=>     int(4)     ["canviewothersusernotes"]=>     int(8)     ["canmanageownusernotes"]=>     int(16)     ["canseehidden"]=>     int(32)     ["canbeusernoted"]=>     int(64)     ["canprofilepic"]=>     int(128)     ["cananimateprofilepic"]=>     int(134217728)     ["canuseavatar"]=>     int(512)     ["cananimateavatar"]=>     int(67108864)     ["canusesignature"]=>     int(1024)     ["canusecustomtitle"]=>     int(2048)     ["canseeprofilepic"]=>     int(4096)     ["canviewownusernotes"]=>     int(8192)     ["canmanageothersusernotes"]=>     int(16384)     ["canpostownusernotes"]=>     int(32768)     ["canpostothersusernotes"]=>     int(65536)     ["caneditownusernotes"]=>     int(131072)     ["canseehiddencustomfields"]=>     int(262144)     ["canseeownrep"]=>     int(256)     ["canuserep"]=>     int(524288)     ["canhiderep"]=>     int(1048576)     ["cannegativerep"]=>     int(2097152)     ["cangiveinfraction"]=>     int(4194304)     ["canseeinfraction"]=>     int(8388608)     ["cangivearbinfraction"]=>     int(536870912)     ["canreverseinfraction"]=>     int(16777216)     ["cansearchft_bool"]=>     int(33554432)     ["canemailmember"]=>     int(268435456)   }   ["genericoptions"]=>   &array(6) {     ["showgroup"]=>     int(1)     ["showbirthday"]=>     int(2)     ["showmemberlist"]=>     int(4)     ["showeditedby"]=>     int(8)     ["allowmembergroups"]=>     int(16)     ["isnotbannedgroup"]=>     int(32)   }   ["signaturepermissions"]=>   &array(17) {     ["canbbcode"]=>     int(131072)     ["canbbcodebasic"]=>     int(1)     ["canbbcodecolor"]=>     int(2)     ["canbbcodesize"]=>     int(4)     ["canbbcodefont"]=>     int(8)     ["canbbcodealign"]=>     int(16)     ["canbbcodelist"]=>     int(32)     ["canbbcodelink"]=>     int(64)     ["canbbcodecode"]=>     int(128)     ["canbbcodephp"]=>     int(256)     ["canbbcodehtml"]=>     int(512)     ["canbbcodequote"]=>     int(1024)     ["allowimg"]=>     int(2048)     ["allowsmilies"]=>     int(4096)     ["allowhtml"]=>     int(8192)     ["cansigpic"]=>     int(32768)     ["cananimatesigpic"]=>     int(65536)   } }
Any assistance is much appreciated.

Thanks,

d4
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01303 seconds
  • Memory Usage 1,808KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete