View Single Post
  #1326  
Old 11-26-2004, 12:44 PM
Silverstangs Silverstangs is offline
 
Join Date: Nov 2003
Location: Roseville Sacramento CA
Posts: 93
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey Magnus & Action-N
For the Add-on Add "latest Uploads" to FORUMHOME by magnus..

When I use the following in your instructions for Vb 3.0.1 it works fine but......
it does not work when I use those for vb 3.0.3. on my test machine or main forum.


In index.php:
FIND:
PHP Code:
// ### WELCOME MESSAGE ################################################# 
Add ABOVE:
PHP Code:
// START VBGARAGE HACK 
// ### VBGARAGE ######################################################### 
$result_latest $DB_site->query(
    SELECT vbgarage_images.* 
    FROM " 
TABLE_PREFIX "vbgarage_images 
    ORDER BY vbgarage_images.vbgarageid DESC 
    LIMIT 5 
"
); 
      
while (
$latest $DB_site->fetch_Array($result_latest)) 

    eval(
'$latestbits .= "' fetch_template('vbgarage_latestbits') . '";'); 


$DB_site->free_result($result_latest); 
// END VBGARAGE HACK 
In includes/init.php
Find:
PHP Code:
// field names for general permissions
$_BITFIELD['usergroup']['genericpermissions'] = array(
    
'canviewmembers'           => 1,
    
'canmodifyprofile'         => 2,
    
'caninvisible'             => 4,
    
'canviewothersusernotes'   => 8,
    
'canmanageownusernotes'    => 16,
    
'canseehidden'             => 32,
    
'canbeusernoted'           => 64,
    
'canprofilepic'            => 128,
    
'canuseavatar'             => 512,
    
'canusesignature'          => 1024,
    
'canusecustomtitle'        => 2048,
    
'canseeprofilepic'         => 4096,
    
'canviewownusernotes'       => 8192,
    
'canmanageothersusernotes' => 16384,
    
'canpostownusernotes'      => 32768,
    
'canpostothersusernotes'   => 65536,
    
'caneditownusernotes'      => 131072,
    
'canseehiddencustomfields' => 262144
And add:
PHP Code:
    'canvbgarage'              => 524288


************************************* CHANGES I HAD TO DO***************
For vb 3.0.3. I had to use the following changes to your instructions in
order to get the Add-on Add "latest Uploads" to FORUMHOME by magnus..
for vbgarage to work. I tried it on 4 different test machines, two running 3.0.1
and two running 3.0.3. Freash installs for all 4 attempts, with the timeslips
hack and vbadvanced installed. I seem to run into two issues. The first issue
is with index.php. I get the error that I posted earlier
Quote:
Database error in vBulletin 3.0.3:

Invalid SQL:
SELECT vbgarage_images.*
FROM vb3vbgarage_images
ORDER BY vbgarage_images.vbgarageid DESC
LIMIT 5

mysql error: Unknown table 'vbgarage_images'

mysql error number: 1051

Date: Wednesday 24th of November 2004 08:19:06 AM
Script: http://www.stangcountry.com/forums/index.php?
Referer: http://www.stangcountry.com/forums/...dex.php?do=head
Username: Silverstangs
IP Address: 69.xxx.xxx.xxx


The second is with init.php. I'm not sure exactly what the issue is
but I have noticed that I can not use any number higher than 262144.
When I attempt to use the number 524288 it seems to have the option
Can use vBGarage? in the Usergroup Manager under
General Permissions to always be set to No for all the
users except for the admins. I attempt to switch it on, with several different
computers, and it won't stick. I get the same results with the test machines.
I don't know if you can confirm the issue I have found, but hopefully this can
help you all or someone else.

************************************************** **********************


In index.php:
FIND:
PHP Code:
// ### WELCOME MESSAGE ################################################# 

Add ABOVE:
PHP Code:
// START VBGARAGE HACK 
// ### VBGARAGE ######################################################### 
$result_latest $DB_site->query(
    SELECT * 
    FROM " 
TABLE_PREFIX "vbgarage_images 
    ORDER BY vbgarageid DESC 
    LIMIT 5 
"
); 
      
while (
$latest $DB_site->fetch_Array($result_latest)) 

    eval(
'$latestbits .= "' fetch_template('vbgarage_latestbits') . '";'); 


$DB_site->free_result($result_latest); 
// END VBGARAGE HACK 

In includes/init.php
Find:
PHP Code:
// field names for general permissions
$_BITFIELD['usergroup']['genericpermissions'] = array(
    
'canviewmembers'           => 1,
    
'canmodifyprofile'         => 2,
    
'caninvisible'             => 4,
    
'canviewothersusernotes'   => 8,
    
'canmanageownusernotes'    => 16,
    
'canseehidden'             => 32,
    
'canbeusernoted'           => 64,
    
'canprofilepic'            => 128,
    
'canuseavatar'             => 512,
    
'canusesignature'          => 1024,
    
'canusecustomtitle'        => 2048,
    
'canseeprofilepic'         => 4096,
    
'canviewownusernotes'       => 8192,
    
'canmanageothersusernotes' => 16384,
    
'canpostownusernotes'      => 32768,
    
'canpostothersusernotes'   => 65536,
    
'caneditownusernotes'      => 131072,
    
'canseehiddencustomfields' => 262144
REPLACE with:
PHP Code:
// field names for general permissions
$_BITFIELD['usergroup']['genericpermissions'] = array(
    
'canviewmembers'           => 1,
    
'canmodifyprofile'         => 2,
    
'canvbgarage'              => 4,
    
'canviewothersusernotes'   => 8,
    
'canmanageownusernotes'    => 16,
    
'canseehidden'             => 32,
    
'canbeusernoted'           => 64,
    
'canprofilepic'            => 128,
    
'canuseavatar'             => 512,
    
'canusesignature'          => 1024,
    
'canusecustomtitle'        => 2048,
    
'canseeprofilepic'         => 4096,
    
'canviewownusernotes'       => 8192,
    
'canmanageothersusernotes' => 16384,
    
'canpostownusernotes'      => 32768,
    
'canpostothersusernotes'   => 65536,
    
'caneditownusernotes'      => 131072,
    
'canseehiddencustomfields' => 262144,
    
'caninvisible'             => 524288

Thanks --Scott
--Silverstangs
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01149 seconds
  • Memory Usage 1,854KB
  • 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
  • (8)bbcode_php
  • (1)bbcode_quote
  • (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