Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
vbWiki Standard - vBulletin+MediaWiki integration Details »»
vbWiki Standard - vBulletin+MediaWiki integration
Version: 1.3 RC5, by ElfMage ElfMage is offline
Developer Last Online: Aug 2010 Show Printable Version Email this Page

Category: Integration with vBulletin - Version: 3.6.4 Rating:
Released: 01-11-2007 Last Update: 09-27-2007 Installs: 226
Additional Files  
No support by the author.

Update:

9/28/2007: vbWiki Std v1.3 RC5 is now available for download. This version adds compatibility with MW 1.11.0+

5/17/2007: vbWiki Std v1.3 RC4 is now available for download. This version is compatible with MW 1.10.0+ and vBulletin 3.6.6+

1/21/2007: vbWiki Std v1.0.2 RC3 is now available for download. This version fixes the 'session error' that used to happen on some installations of MediaWiki 1.9.x.

Description:

vbWiki Standard is the lite version of vbWiki Pro. vbWiki Standard allows the integration of vBulletin and MediaWiki user authentication.

(vbWiki Pro is a commercial product that, in addition to the functionality found in vbWiki Standard, provides full skin integration, enhanced user management, Admin CP, editing of wiki skin in vBulletin's Style Manager, among other features.)

Why should you add a wiki to your forums?

Forums are great for community building with their high level of interactivity. Successful forums have hundreds or thousand of concurrent users creating and replying to threads.

However due to this very reason the more your forums grow the more "collective knowledge" is scattered throughout the thousands (or hundreds or millions) of threads in your forums. Making it difficult for users to find and use.

A wiki is not that good at community building, but it is a great medium to centralize this 'collective knowledge'. Enabling you to create an 'ecosystem of information' (quoting pipin ) maintained and contributed by your users.

The idea behind vbWiki (both Standard and Pro) is to enable the seamless integration between these two packages (vBulletin and MediaWiki) side-by-side in your community. You (and your users and community) get the best of both worlds.

Or so the theory goes...

Features:
  • Single sign-on for vBulletin and MediaWiki (users log in only once)
  • Supports mapping of vBulletin usergroups to MediaWiki user roles
  • Users viewing wiki pages are shown in vBulletin's "What's going on?" section (both guests and registered users)
  • Supports auto-authentication, users who choose to be "remembered" are logged in upon visiting the site to both vBulletin and MediaWiki.
Installation:

These installation instructions do not apply to vbWiki Pro. Refer to vbWiki Pro installation instructions for more information.

MediaWiki and vBulletin must be installed and properly working before installing vbWiki. MediaWiki can be downloaded here.
  • Create a new directory in your forums directory named vbWiki.
  • Upload the content of the installation package to this new directory.
  • Rename the file vbWiki_Init.php-dist to vbWiki_Init.php
  • Open the file LocalSettings.php found in your MediaWiki directory in a text editor and at the very end find the following line and remove it if present:
PHP Code:
?> 
  • Add the following code at the end of the file (entering the correct directory path):
PHP Code:
require_once "/absolute/path/to/your/forums/vbWiki/vbWiki_Init.php"
Troubleshooting:

If you run into any trouble installing vbWiki (blank page, logins not working, etc.), follow these instructions to temporarily turn on vbWiki's Diagnostic Tools.

Open vbWiki_Init.php (or vbWikiPro_Init.php) and find this line:

PHP Code:
$run_vbWikiPro_diag_tools false
And change it for this:

PHP Code:
$run_vbWikiPro_diag_tools true
Navigate to the wiki home page, and see the results.

Changes:
  • 0 vBulletin files to Edit
  • 1 MediaWiki file to Edit
  • 10 vbWiki Files to Upload
Requirements:
  • vBulletin v3.5.4 (version 3.6.x recommended)
  • MediaWiki 1.6.8+ (recommended 1.7.x+).
  • PHP4+
Uninstalling...
  • To uninstall vbWiki Standard simply remove (or comment) the line added to LocalSettings.php.
  • Optionally remove the directory vbWiki from your forums directory.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #292  
Old 07-03-2008, 08:05 PM
Smitty's Avatar
Smitty Smitty is offline
 
Join Date: Sep 2002
Location: Southern Ohio
Posts: 385
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Has anyone done vB 3.7.2, Wediawiki 12, and the Pro version?
Reply With Quote
  #293  
Old 07-06-2008, 09:30 PM
swisscotton swisscotton is offline
 
Join Date: Apr 2008
Posts: 40
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I am ready install wiki but just wanted to make sure that this has no chance of messing up your live forum?
Reply With Quote
  #294  
Old 07-07-2008, 04:42 AM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ran across the session logout bug mentioned in this thread. This is how I killed it - I'm not familiar enough with mediaWiki yet to fully weigh the ramifications of this stunt. Use with caution.

In file vbWiki.php find this line of code
PHP Code:
require_once( LUX_VB_DIR "/vbWiki_Hooks.php" ); 
Insert after

PHP Code:
/** Patch - make sure $_SESSION is populated **/
if ((empty($_SESSION['wsUserID']) || empty($_SESSION['wsUserName']) || empty($_SESSION['wsToken'])) && !empty($_COOKIE['seebelow']))
{
    
$_SESSION array_merge$_SESSION$db->query_first("SELECT 
        user_id AS wsUserID,
        user_name AS wsUserName,
        user_token AS wsToken
        FROM mw__user
        WHERE user_name = '"
.addslashes($_COOKIE['seebelow'])."' LIMIT 1"));

To get the above to work you must also change $_COOKIE['seebelow'] following the instructions below. For my board it was

$_COOKIE['enprod_mw__UserName']

This appears to be databasename + underscore + mediawiki prefix + "UserName".

You can discover what the field actually is by calling print_r($_COOKIE); exit; where this code mod occurs to find out what part of the cookie you need to reference to find the username for the wiki.

It is during the code that precedes that vbWiki populates the cookie but for some reason the $_SESSION is left empty - this is why the user is logged out when they go to the wiki and has to log in. Keep in mind that vbulletin doesn't use $_SESSION at all.

The hack above populates $_SESSION with the values necessary to authenticate mediaWiki. It is called after the bridge has already tested the cookie using vbulletin core - so it should be safe.

With the fix above I now have this module running on vBulletin 3.7.2 and MediaWiki 1.12.0
Reply With Quote
  #295  
Old 07-07-2008, 12:36 PM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, if they don't click 'remember me' the above fails. Hmm... I'm close....
Reply With Quote
  #296  
Old 07-08-2008, 12:31 AM
iRO Wiki iRO Wiki is offline
 
Join Date: Sep 2007
Location: Colorado
Posts: 48
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for working to get this compatible. Once you do, is there any chance you can upload a complete working/compatible version of the basic files somewhere?
Reply With Quote
  #297  
Old 07-08-2008, 01:17 AM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by iRO Wiki View Post
Thanks for working to get this compatible. Once you do, is there any chance you can upload a complete working/compatible version of the basic files somewhere?
I will upload the instructions, but legally I can't do anything more since I don't own the rights to the hack.

HOWEVER... I *might* be able to use a plugin.xml to make the transition easier. We'll see. If I can get a plugin to fix the compat issues I can release that as a separate hack of a hack.
Reply With Quote
  #298  
Old 07-08-2008, 03:41 PM
SuperGLS SuperGLS is offline
 
Join Date: Nov 2004
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by iRO Wiki View Post
Thanks for working to get this compatible. Once you do, is there any chance you can upload a complete working/compatible version of the basic files somewhere?
Quote:
Originally Posted by Michael Morris View Post
I will upload the instructions, but legally I can't do anything more since I don't own the rights to the hack.

HOWEVER... I *might* be able to use a plugin.xml to make the transition easier. We'll see. If I can get a plugin to fix the compat issues I can release that as a separate hack of a hack.
I love to see a new write up with simple and clear instructions on compatibility with 3.7 and 1.12. A plug in to make the whole process easy would be wonderful. Thanks for your hard work on this.
Reply With Quote
  #299  
Old 07-09-2008, 04:53 AM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, I've got this down to something reasonably easy to do, but it is still a hack as there seems to be bad code floating about :\

I have managed to narrow down the edits to one file - arcane_vbulletin_core.php

In that file find this code

PHP Code:
// Include vBulletin Engine
    
if ($g_vbWiki_StyleId_Override 0)
    {
        
define('VB_AREA''Forum');
        require_once(
'./includes/init.php');
        
$vbulletin->options['styleid'] = $g_vbWiki_StyleId_Override;
        
$vbulletin->options['allowchangestyles'] = false;                    // ignore user styles
        
$vbulletin->userinfo['styleid'] = 0;
    }
    
    require_once(
'./global.php');
    require_once(
'./includes/functions_login.php');
    require_once(
"./includes/functions.php");                // vbdate
    
require_once("./includes/functions_forumdisplay.php");
    require_once(
"./includes/functions_newpost.php");
    require_once(
"./includes/adminfunctions.php" ); 
A LOT of libraries are being included there, and I *think* most of them are only used by the pro-integration. I changed that whole block to the following.

PHP Code:
    require_once('./global.php');

    if ((empty(
$_SESSION['wsUserID']) || empty($_SESSION['wsUserName']) || empty($_SESSION['wsToken'])) 
        && !empty(
$_COOKIE[$wgDBname.'_'.$wgDBprefix.'UserName']))
    {
        
$_SESSION array_merge$_SESSION$db->query_first("SELECT 
            user_id AS wsUserID,
            user_name AS wsUserName,
            user_token AS wsToken
            FROM "
.$wgDBname.".".$wgDBprefix."user
            WHERE user_name = '"
.addslashes($_COOKIE[$wgDBname.'_'.$wgDBprefix.'UserName'])."' LIMIT 1"));
    } 
That should fix this plug in to work with mediaWiki 1.12 and vbulletin 3.7 HOWEVER I do not guarantee the pro version will work and I also suspect that users with cookies disabled or blocked will still experience log out troubles.
Reply With Quote
  #300  
Old 07-09-2008, 09:06 PM
SuperGLS SuperGLS is offline
 
Join Date: Nov 2004
Posts: 126
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So all we do is install MW 1.12, vBwiki Standard, and then make the changes in post 298 (the one above this one) and it should work? Sounds too easy! Thanks.
Reply With Quote
  #301  
Old 07-10-2008, 02:26 AM
Michael Morris's Avatar
Michael Morris Michael Morris is offline
 
Join Date: Nov 2003
Location: Knoxville TN
Posts: 774
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by SuperGLS View Post
So all we do is install MW 1.12, vBwiki Standard, and then make the changes in post 298 (the one above this one) and it should work? Sounds too easy! Thanks.
Yes. If you run into problems I will try to help as I find the time.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 11:21 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.11232 seconds
  • Memory Usage 2,343KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (8)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • 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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete