Resource icon

[SchmitzIT] XenForo MediaWiki Bridge 2.0

No permission to download
Happened upon an error when attempting to test admindav.php from XenForo:
Code:
ErrorException: Declaration of MediaWiki_Dependencies_Public::route() should be compatible with that of XenForo_Dependencies_Abstract::route() - library/MediaWiki/Dependencies/Public.php:2
Generated By: Unknown Account, 1 minute ago

Stack Trace
#0 /forums/public/library/MediaWiki/Dependencies/Public.php(2): XenForo_Application::handlePhpError(2048, 'Declaration of ...', '/forums/public/...', 2, Array)
#1 /forums/public/library/XenForo/Autoloader.php(119): include('/forums/public/...')
#2 [internal function]: XenForo_Autoloader->autoload('MediaWiki_Depen...')
#3 [internal function]: spl_autoload_call('MediaWiki_Depen...')
#4 /wiki/public/extensions/XenForo/setup.php(93): class_exists('MediaWiki_Depen...')
#5 [internal function]: MWXF_Setup::init()
#6 /wiki/public/includes/Setup.php(551): call_user_func('MWXF_Setup::ini...')
#7 /wiki/public/includes/WebStart.php(157): require_once('/forums/public/...')
#8 /wiki/public/index.php(55): require('/forums/public/...')
#9 {main}
Request State
array(3) {
  ["url"] => string(22) "http://wiki.domian.tld/"
  ["_GET"] => array(1) {
    ["title"] => string(0) ""
  }
  ["_POST"] => array(0) {
  }
}

Is this 1.2?
 
Can the recent-activity be truncated? The complete mediawiki page is being shown right now and showing just the line that a page is edited would be preferred.

The code for truncating works but is always showing wiki code rather than text from the page. Is there a way to strip out the wiki code and just get the text?

Recent Activity | Tux Reports Network Community Connect 2013-07-01 08-25-52.webp
 
Future reference for anyone that encounters this issue:
I ran into an odd problem where, if (and only if) this extension was enabled in MediaWiki, the wiki would fail to load at all with a content encoding error. Turns out that I didn't have zlib.output_compression enabled in my PHP settings! Enabled it and all is well.
 
@Wulfspider @Travis

To get your wiki to load again in 1.2.x, you can change the following. This is not a *full* fix for 1.2, but it'll at least allow you to auto-login and see your content.

In:
MediaWiki/Dependencies/Public.php

Find:
PHP:
public function route(Zend_Controller_Request_Http $request) {

        return new XenForo_RouteMatch('MediaWiki_ControllerPublic', 'External', 'external');
    }

Change to:
PHP:
public function route(Zend_Controller_Request_Http $request, $routePath = null) {
        return new XenForo_RouteMatch('MediaWiki_ControllerPublic', 'External', 'external'
);
    }
 
Last edited:
whooop.webp

Whoopsieeee...

Also, commented it out so the wiki works now... But something ain't working right.

Xenforo version: 1.2.1
Mediawiki version: 1.20.3 (You can see the version and extensions it may conflict with here: http://zelda-sanctuary.net/wiki/Special:Version ).

(Also, still working on the colors in the mediawiki theme...Sshhh).
 
@Wulfspider @Travis

Change to:
PHP:
public function route(Zend_Controller_Request_Http $request, $routePath = null) {
        return new XenForo_RouteMatch('MediaWiki_ControllerPublic', 'External');
    }

Actually, it looks like you're missing a parameter.

Here's my edit, and it seems to work with this on 1.2 on our site:

Code:
    public function route(Zend_Controller_Request_Http $request, $routePath = null) {
        return new XenForo_RouteMatch('MediaWiki_ControllerPublic', 'External', 'external');
    }

Note the extra "'external'" in the second line.
 
Note the extra "'external'" in the second line.
Ah, yep. Your right. Going to edit my original post. Got a little caught up in the backspacing. ^_^

@AtrumLevis That's most likely an issue with how your server is handling compression. Might be worthwhile to have a look at Gzip settings in regards to MediaWiki.
 
I cannot get this working in XenForo 1.2.3.

Using MediaWiki 1.21.2. My wiki is installed in the root of my site and the XenForo is installed in /forums. However, when enabled I see no link which allows a user to login via the forum.

I've disabled the plugin (for now).
 
@Digital Doctor

I am wondering why are the XenForo install steps 'optional'? Surely these are required for XenForo to even recognise MediaWiki? I have installed just the MediaWiki extension and when activated I see no login/logout link that points to my forums? I will try the fixes (though it's unclear where public.php is).
 
@Digital Doctor

I am wondering why are the XenForo install steps 'optional'? Surely these are required for XenForo to even recognise MediaWiki? I have installed just the MediaWiki extension and when activated I see no login/logout link that points to my forums? I will try the fixes (though it's unclear where public.php is).

It's optional because the core functionality of the bridge is to synchronize the logins. If you want to show wiki activity in your forums, then you can use the optional steps.

I'll see if I can work on a slightly updated version that includes the fix from above.

In the meantime, the public.php file is in /library/MediaWiki/Dependencies, exactly where @Iversia's post states it is .
 
Using MediaWiki 1.21.2. My wiki is installed in the root of my site and the XenForo is installed in /forums. However, when enabled I see no link which allows a user to login via the forum.

I've disabled the plugin (for now).

When I head to the /forums path of your site, I do not see a XenForo installation:

http://www.channelwiki.org/forums/

Where's the XenForo installation, exactly, and can you show us the edits that you made as specified in the installation instructions?
 
When I head to the /forums path of your site, I do not see a XenForo installation:

http://www.channelwiki.org/forums/

Where's the XenForo installation, exactly, and can you show us the edits that you made as specified in the installation instructions?
@SchmitzIT - It's back. Many thanks for your reply. I was just testing WordPress. I'll post the code later from my MediaWiki install.

I'm certainly preferring XenForo to BBPress.
 
Xenforo + Mediawiki + Wordpress = Best of breed x 3.

Before you get too into Mediawiki ... check out Vaultwiki.
It's as Powerful as Mediawiki but integrated into the forums.

I think Vaultwiki is better than Mediawiki. My only criticism of Vaultwiki is that it is "almost as hard" to use as Mediawiki is.

Mediawiki is powerful, but the steep learning curve prevent community-generated documents from being a reality.
 
Back
Top Bottom