Project:Support desk/Sections/Extension

__NEWSECTIONLINK__

= Extension Support =

(RESOLVED) EmbedImg Extension, Advice rather than tech help needed on Images

 * Product Version MediaWiki 1.14alpha (r45489)
 * PHP 5.2.4-2ubuntu5wm1 (apache2handler)
 * MySQL 4.0.40-wikimedia-log
 * www.trialworks.com/wiki

Hello, This is more of an "advice needed" post. I wanted to use the Upload/Image functions in MediaWiki but I believe I cannot... my webhost does not give me easy access to php.ini and I really don't want to go through the headaches of making them enable uploads in PHP, so I've kind of given up.

I did, however, download EmbedImg Extension and absolutely love it. It lets me take a address to an JPG or PNG file and paste it into the wiki, and in turn it displays the image (Rather than the path). The problem is that it's parameters only let me change size, but not location. I need to be able to align those images "right" with text, so that it all looks good. Aside from the extension, I got around the upload system by writing, in ColdFusion, an upload agent. It lets any of my users - in a super simple fashion - upload an image to the site and obtain the link, which then goes into the Wiki Article. It's really simple but very effective for my needs.

So now, I am just dealing with a formatting issue. It needs to be uber easy for my users. How would you guys/girls handle the alignment or would you really work on getting the Wiki upload stuff to work (btw, I feel my ColdFusion app is easier to use for my users than the Wiki stuff).

Karl @ www.trialworks.com/wiki Thanks!!


 * UPDATE: sorry to waste space, I think I've solved my little crisis with

MediaWiki oes not find texvc - but texvc exist in the math folder !!!

 * MediaWiki version: 1.13.3
 * PHP version: 5.2.4
 * MySQL version: 5.0.51a
 * URL: not public ... local network

Hi there,

I need help, cause I tried serveral times to setup texvc for our MediaWiki. I downloaded and installed the latest version of OCaml and run the 3 steps:

1. Change to the "math" sub-directory of your MediaWiki install 2. Run 'make' (or 'gmake' if GNU make is not your default make). This should produce the texvc executable. 3. Enable $wgUseTeX and $wgEnableUploads in your LocalSettings.php and everything should work.

I've seen no errors during the make but the MediaWiki does still not find the texvc !!! I checked the math folder and there is an texvc...

how can I resolve the problem ???

thank you !!!

Alex

I have some problem with mediawiki-1.13.3-42.fc10.x86_64 on fedora 10 x86_64 and resolved it from http://zaphod.lite.msu.edu/bugzilla/show_bug.cgi?id=5757. The solution was to run texinfo rehash, and run fmtutil-sys --missing. Ivan

How-to restrict access to a Special Page? (Resolved)

 * MediaWiki version: 1.13
 * PHP version:  5.0

Hi,

I'm using the extension http://www.mediawiki.org/wiki/Extension:UploadCSV where I can update pages with an CSV file. As this extension can easily cause vandalism, I want to restrict the access for just "administrators". Like when trying to access this page as a normal user: http://meta.wikimedia.org/wiki/Special:Block

I added:

$wgGroupPermissions['*']['uploadcsv'] = false; $wgGroupPermissions['sysop']['uploadcsv'] = true;

to LoaclSettings.php - but everyone can still access the page. Any ideas what I'm doing wrong?

Thanks, Chris

add to uploadCSV.php

// New user right - required to access Special:Maintenance $wgAvailableRights[] = 'uploadcsv';

function wfUploadCSVStart { global $wgMessageCache, $ExtensionTitles, $wgOut, $wgUser;

# If the user doesn't have the required 'maintenance' permission, display an error if( !$wgUser->isAllowed( 'uploadcsv' ) ) { $wgOut->permissionRequired( 'uploadcsv' ); return; }

add to LocalSettings.php

$wgGroupPermissions['sysop']['uploadcsv'] = true;

Extension Licensing Guidelines
I was wondering if there were licensing guidelines for extensions. I am combined several extensions with MediaWiki and noticed that some of the extensions have licenses that are incompatible with other extensions (e.g. Affero v.3 with a majority of extensions under GPL v.2). There are also several extensions that have no license indicated--is there a default license if you are coding for combination with MediaWiki? I was wondering if there was already guidance or if there could be some written on these topics. Thanks.

FlaggedRevs: Setting Stable view by default

 * MediaWiki version: 1.12.0
 * PHP version: 5.2.6-1+lenny3
 * MySQL version: 5.0.51a-24+lenny1
 * Extension: FlaggedRevs-MW1.12-r31252

Hi. Can I set the STABLE view TAB by default instead of the current one in all articles ? (What I mean is: When someone goes to an article link, it has to show its stable version) I know there's a method using the URL with "&stable=1" but I need to set this variable a default value without specifying it at the URL.

(I think that if I modify the src code it can be done, but I prefer not to do it unless that's the only way).

Is it possible ?

Thank you in advance. Alejandro

—200.123.101.200 15:18, 27 July 2009 (UTC)

MultipleUpload Extension installation error

 * MediaWiki version: 1.15.1
 * PHP version: 5.2.6
 * MySQL version: 5.0.81-community
 * URL: http://ethersagaclub.com/wiki

After trying to install the MultipleUpload Extension to my wiki under the /extensions directory and put in require_once("extensions/MultiUpload/SpecialMultipleUpload.php"); in the LocalSettings.php file, I get the following error:

Warning: require_once [function.require-once]: URL file-access is disabled in the server configuration in /home/esclub/public_html/wiki/LocalSettings.php on line 128

Warning: require_once(http://ethersagaclub.com/wiki/extensions/MultiUpload/SpecialMultipleUpload.php) [function.require-once]: failed to open stream: no suitable wrapper could be found in /home/esclub/public_html/wiki/LocalSettings.php on line 128

Fatal error: require_once [function.require]: Failed opening required 'http://ethersagaclub.com/wiki/extensions/MultiUpload/SpecialMultipleUpload.php' (include_path='/home/esclub/public_html/wiki:/home/esclub/public_html/wiki/includes:/home/esclub/public_html/wiki/languages:.:/usr/lib/php:/usr/local/lib/php') in /home/esclub/public_html/wiki/LocalSettings.php on line 128

Line 128 is where I put the require_once code at.

—76.173.106.64 06:31, 26 August 2009 (UTC)

Copy-past with effect of automatic upload extension

 * MediaWiki version: 1.15.1
 * PHP version: 5

Hi, I don't find an extension that behaves such: when saving a wiki entry, all the lines like (say):

file:///home/user/network.txt file:///home/user/images/nice.png http://www.wishuponaster.com/photos/horse0.jpg

will be processed by the effect of:


 * 1) uploading the file to the wiki server from the local disk (two first cases) or from the internet (last one)
 * 2) have this material displayed in the wiki by appearing as:

[[media:network.txt]]

in the same place as the original location was given.

Does such an extension exist? Is there anything bad in its design if I'd like to write it?

—152.78.195.139 20:22, 9 September 2009 (UTC)

How can I get the page title with php instead of MagicWord { { PAGENAME } }

 * MediaWiki version: 1.15.1
 * PHP version: 5.2.6 (apache2handler)
 * MySQL version: 5.0.51b-community
 * URL: test-system on localhost

I wrote an extension replacing an specific tag in the wikitext. This extension needs to get the page title.

That's how I did it: the extension gets the url from $_SERVER['REQUEST_URI'] and extracts the title with regexp.

Problem: now I have to edit this pages containing the specific tag via curl through a special page, and $_SERVER['REQUEST_URI'] has no result anymore, since the extension is executed by api.php?action=edit.

Question: How can I pass the page title to the extension's script? I tried , resulting in $args['page']= { {PAGENAME} } instead of the desired title of the page... I tried it with $wgPageName, too, but no result.

Can someone help please?

—92.193.2.185 21:20, 12 September 2009 (UTC)