The database schema changed considerably between 1.4.x and 1.5. You
shouldn't expect user mods written for 1.5 which access the DB to work
on a 1.4 installation.
--
Rick DeNatale
Thanks, I figured that was the issue. Is there a detailed listing of changes
for the schema located anywhere online?
Hi,
I tried to upgrade from 1.3.5 to 1.5.4 not direct over 1.4.10
I installed 1.4.10 in [1] but I chose instaed as language "de" "da"
and so the language was danish.
However it works. After this I tried to install 1.5.4 in [2] with the
right langage "de" ;)
Here you can see the install log [3]
But now the languages are mixed the main is danish. but some of the
settings are german
Look here: [4]
I havnt an shell access for php rebuildMessages.php --rebuild
What can I do ?
Best regards
Stephan
[1] http://wiki.sherz.net/1410/
[2] http://wiki.sherz.net/154/
[3] http://sherz.pastebin.com/376042
[4] http://wiki.sherz.net/154/index.php/Special:Allmessages
Can someone help me on some questions
Hi all,
I set up a wiki 1.4.10 on a Fedora Core 4 server.
I enabled squid caching and Zend Php accelerator.
Now I have the following two problems.
1. The User Ip on the top right coner always is
127.0.0.1 instead of the real user's PC IP.
2. after the user edit a page and save that page,
anyone hit the link of that page and take directly to
the Edit page rather that the content of the page.
Any suggestions/
thanks
judi
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
Can someone help me on some questions
Hi all,
I set up a wiki 1.4.10 on a Fedora Core 4 server.
I enabled squid caching and Zend Php accelerator.
Now I have the following two problems.
1. The User Ip on the top right coner always is
127.0.0.1 instead of the real user's PC IP.
2. after the user edit a page and save that page,
anyone hit the link of that page and take directly to
the Edit page rather that the content of the page.
Any suggestions/
thanks
judi
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
Got the link and I do have some code to build the dropdowns, it's more
of a case of editing this code to pull sub-categories to add to the drop
down. Again, I'm very new to PHP and the wiki DB.
<?php
/*
Purpose: outputs a bulleted list of most recent
items residing in a category, or a union
of several categories.
Contributors: n:en:User:IlyaHaykinson n:en:User:Amgine
http://en.wikinews.org/wiki/User:Amginehttp://en.wikinews.org/wiki/User:IlyaHaykinson
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
http://www.gnu.org/copyleft/gpl.html
Current feature request list
1. Unset cached of calling page
2. Alternative formatting (not just unordered list)
3. Configurable sort order, ascending/descending
4. RSS feed output?
To install, add following to LocalSettings.php
include("extensions/dynamicpagelist.php");
*/
$wgDLPminCategories = 1; // Minimum number of
categories to look for
$wgDLPmaxCategories = 3; // Maximum number of
categories to look for
$wgDLPMinResultCount = 1; // Minimum number of results
to allow
$wgDLPMaxResultCount = 50; // Maximum number of results
to allow
$wgDLPAllowUnlimitedResults = true; // Allow unlimited results
$wgDLPAllowUnlimitedCategories = false; // Allow unlimited categories
/**
* Name: DynamicPageList 1.5 for MW 1.4.6
* ***
* Purpose: To support MW 1.4.x
* ***
* @package Mediawiki
* @subpackage DynamicPageList
* @author n:User:IlyaHaykinson
* @author m:User:Amgine
* @version $Alpha 0.1$
* *** */
$wgExtensionFunctions[] = "wfDynamicPageList";
/**
* Name: wfDynamicPageList
* ***
* Purpose: Establishes DynamicPageList extension
* ***
* @return NULL
* *** */
function wfDynamicPageList() {
global $wgParser, $wgMessageCache;
$wgMessageCache->addMessages( array(
'dynamicpagelist_toomanycats' =>
'DynamicPageList: Too many categories!',
'dynamicpagelist_toofewcats' =>
'DynamicPageList: Too few categories!',
'dynamicpagelist_noresults' =>
'DynamicPageList: No results!',
)
);
$wgParser->setHook( "DynamicPageList", "RenDynamicPageList" );
$wgParser->replaceVariables($text, end( $wgParser->mArgStack ));
}
/**
* Name: DynamicPageList
* ***
* Purpose: The callback function for converting the input parameters to
HTML output
* ***
* @param string $input cr/nl delimited parameter list consisting of
key=value.
* @return string $output raw html inserted into page.
* *** */
function RenDynamicPageList( $input ) {
global $wgUser, $wgContLang;
global $wgDLPminCategories,
$wgDLPmaxCategories,$wgDLPMinResultCount, $wgDLPMaxResultCount;
global $wgDLPAllowUnlimitedResults, $wgDLPAllowUnlimitedCategories;
global $wgMessageCache, $wgOutputPage;
global $wgTitle, $wgUseTidy;
// disable cache
$dbw =& wfGetDB( DB_MASTER );
$dbw->update( 'cur', array( 'cur_touched' => $dbw->timestamp( time()
+ 120 ) ),
array(
'cur_namespace' => $wgTitle->getNamespace(),
'cur_title' => $wgTitle->getDBkey()
), 'BrowserOsDetect'
);
$aParams = array();
$bCountSet = false;
$sStartList = '<ul>';
$sEndList = '</ul>';
$sStartItem = '<li>';
$sEndItem = '</li>';
$sOrderMethod = 'categoryadd';
$sOrder = 'descending';
$bNamespace = false;
$iNamespace = 0;
$bSuppressErrors = false;
$bShowNamespace = true;
$aParams = explode("\n", $input);
foreach($aParams as $sParam)
{
$aParam = explode("=", $sParam);
if( count( $aParam ) < 2 )
continue;
$sType = strtolower(trim($aParam[0]));
$sArg = trim($aParam[1]);
if ($sType == 'category')
{
$title = Title::newFromText( $sArg );
if( is_null( $title ) )
continue;
$aCategories[] = $title;
}
else if ($sType == 'notcategory')
{
$title = Title::newFromText( $sArg );
if( is_null( $title ) )
continue;
$aExcludeCategories[] = $title;
}
else if ('namespace' == $sType)
{
//$ns = $wgContLang->getNsIndex($sArg);
//if (NULL != $ns)
//{
//$iNamespace = $ns;
//$bNamespace = true;
//}
//else
//{
$iNamespace = intval($sArg);
if ($iNamespace >= 0)
{
$bNamespace = true;
}
else
{
$bNamespace = false;
}
//}
}
else if ('count' == $sType)
{
//ensure that $iCount is a number;
$iCount = IntVal( $sArg );
$bCountSet = true;
}
else if ('mode' == $sType)
{
switch ($sArg)
{
case 'none':
$sStartList = '';
$sEndList = '';
$sStartItem = '';
$sEndItem = '<br/>';
break;
case 'ordered':
$sStartList = '<ol>';
$sEndList = '</ol>';
$sStartItem = '<li>';
$sEndItem = '</li>';
break;
case 'unordered':
default:
$sStartList = '<ul>';
$sEndList = '</ul>';
$sStartItem = '<li>';
$sEndItem = '</li>';
break;
}
}
else if ('order' == $sType)
{
switch ($sArg)
{
case 'ascending':
$sOrder = 'ascending';
break;
case 'descending':
default:
$sOrder = 'descending';
break;
}
}
else if ('ordermethod' == $sType)
{
switch ($sArg)
{
case 'lastedit':
$sOrderMethod = 'lastedit';
break;
case 'alphabetic':
$sOrderMethod = 'alphabetic';
break;
case 'categoryadd':
default:
$sOrderMethod = 'categoryadd';
break;
}
}
else if ('suppresserrors' == $sType)
{
if ('true' == $sArg)
$bSuppressErrors = true;
}
else if ('shownamespace' == $sType)
{
if ('false' == $sArg)
$bShowNamespace = false;
}
}
$iCatCount = count($aCategories);
$iExcludeCatCount = count($aExcludeCategories);
$iTotalCatCount = $iCatCount + $iExcludeCatCount;
if ($iCatCount < 1 && false == $bNamespace)
{
if (false == $bSuppressErrors)
return htmlspecialchars( wfMsg( 'dynamicpagelist_noincludecats'
) ); // "!!no included categories!!";
else
return '';
}
if ($iTotalCatCount < $wgDLPminCategories)
{
if (false == $bSuppressErrors)
return htmlspecialchars( wfMsg( 'dynamicpagelist_toofewcats' )
); // "!!too few categories!!";
else
return '';
}
if ( $iTotalCatCount > $wgDLPmaxCategories &&
!$wgDLPAllowUnlimitedCategories )
{
if (false == $bSuppressErrors)
return htmlspecialchars( wfMsg( 'dynamicpagelist_toomanycats' )
); // "!!too many categories!!";
else
return '';
}
if ($bCountSet)
{
if ($iCount < $wgDLPMinResultCount)
$iCount = $wgDLPMinResultCount;
if ($iCount > $wgDLPMaxResultCount)
$iCount = $wgDLPMaxResultCount;
}
else
{
if (!$wgDLPAllowUnlimitedResults)
{
$iCount = $wgDLPMaxResultCount;
$bCountSet = true;
}
}
//build the SQL query
$dbr =& wfGetDB( DB_SLAVE );
$sPageTable = $dbr->tableName( 'cur' );
$categorylinks = $dbr->tableName( 'categorylinks' );
$sSqlSelectFrom = "SELECT cur_namespace, cur_title FROM
$sPageTable";
if (true == $bNamespace)
$sSqlWhere = ' WHERE cur_namespace='.$iNamespace.' AND
cur_is_redirect=0 AND cur_id = c1.cl_from ';
else
$sSqlWhere = ' WHERE cur_id = c1.cl_from ';
for ($i = 0; $i < $iCatCount; $i++) {
$sSqlSelectFrom .= " INNER JOIN $categorylinks AS c" .
($iCurrentTableNumber+1);
$sSqlSelectFrom .= ' ON cur_id =
c'.($iCurrentTableNumber+1).'.cl_from';
$sSqlSelectFrom .= ' AND c'.($iCurrentTableNumber+1).'.cl_to='.
$dbr->addQuotes( $aCategories[$i]->getDbKey() );
$iCurrentTableNumber++;
}
for ($i = 0; $i < $iExcludeCatCount; $i++) {
$sSqlSelectFrom .= " LEFT OUTER JOIN $categorylinks AS c" .
($iCurrentTableNumber+1);
$sSqlSelectFrom .= ' ON cur_id =
c'.($iCurrentTableNumber+1).'.cl_from';
$sSqlSelectFrom .= ' AND c'.($iCurrentTableNumber+1).'.cl_to='.
$dbr->addQuotes( $aExcludeCategories[$i]->getDbKey() );
$sSqlWhere .= ' AND c'.($iCurrentTableNumber+1).'.cl_to IS NULL';
$iCurrentTableNumber++;
}
if ('descending' == $sOrder)
$sSqlOrder = 'DESC';
else
$sSqlOrder = 'ASC';
if ('lastedit' == $sOrderMethod)
$sSqlWhere .= ' ORDER BY cur_touched ';
elseif ('alphabetic' == $sOrderMethod)
$sSqlWhere .= ' ORDER BY cur_title ';
else
$sSqlWhere .= ' ORDER BY c1.cl_timestamp ';
$sSqlWhere .= $sSqlOrder;
if ($bCountSet)
{
$sSqlWhere .= ' LIMIT ' . $iCount;
}
//DEBUG: output SQL query
//$output = $sSqlSelectFrom . $sSqlWhere . "<br />\n";
// process the query
$res = $dbr->query($sSqlSelectFrom . $sSqlWhere);
$sk =& $wgUser->getSkin();
if ($dbr->numRows( $res ) == 0)
{
if (false == $bSuppressErrors)
return htmlspecialchars( wfMsg( 'dynamicpagelist_noresults' ) );
else
return '';
}
//start unordered list
$output .= $sStartList . "\n";
//process results of query, outputing equivalent of
<li>[[Article]]</li> for each result,
//or something similar if the list uses other startlist/endlist
while ($row = $dbr->fetchObject( $res ) ) {
$title = Title::makeTitle( $row->cur_namespace, $row->cur_title);
$output .= $sStartItem;
if (true == $bShowNamespace)
$output .= $sk->makeKnownLinkObj($title);
else
$output .= $sk->makeKnownLinkObj($title,
htmlspecialchars($title->getText()));
$output .= $sEndItem . "\n";
}
//end unordered list
$output .= $sEndList . "\n";
return $output;
}
?>
-----Original Message-----
From: mediawiki-l-bounces(a)Wikimedia.org
[mailto:mediawiki-l-bounces@Wikimedia.org] On Behalf Of Andrea Forte
Sent: Monday, September 26, 2005 6:11 PM
To: MediaWiki announcements and site admin list
Subject: Re: [Mediawiki-l] Taxonomy, navigation and hacking
I don't know if this is quite what you were looking for, but I bet you
could modify this to do nested links...
http://www.dynamicdrive.com/dynamicindex17/switchcontent.htm
andrea
As an aside to this, how do we get a link to open up in a new instance of the browser, as in the HTML target="_blank"? That might help with the PDF's?
Regards,
Andrew
MediaWiki: 1.4.5
PHP: 4.3.10 (cgi)
MySQL: 4.0.25-standard-log
-----Original Message-----
From: mediawiki-l-bounces(a)Wikimedia.org
[mailto:mediawiki-l-bounces@Wikimedia.org]On Behalf Of Con Rodi
Sent: 27 September 2005 16:27
To: MediaWiki announcements and site admin list
Subject: Re: [Mediawiki-l] Allow PDF uploads?
Randy, I would not say it "breaks" the Special:Newimages page. The
PDFs show up as blank images. Sure, they take up space, but it
doesn't seem to be a big deal.
Rob, some browsers do indeed render the a pdf inline in the wiki page
(at least Safari does this). The problem I've had in doing this is
that it seems to take a very long time to download the files and
render them--much longer than a comparably sized JPG file. On one
Win XP computer IE took so long we gave up. So my practice is to
point to the image page and let people download the document from
there. At least if it takes a while, they understand they asked for
something unusual.
It would be nice to be emancipated from the Image terminology when
working with documents, but, hey, this at least works.
Con
On Sep 27, 2005, at 11:16 AM, Randy Plemel wrote:
> The only problem of using pdf as an image, is that it breaks the
> Special:Newimages page, and any Special page or gallery view of
> images, because it can't render pdf as an image file.
>
> If somehow you could not have pdf's show up in Special:Newimages (or
> similar pages), then uploading pdf's would be great.
>
> Randy
> http://archiporn.com
>
> On 9/27/05, Rob Church <robchur(a)gmail.com> wrote:
>
>> Yeah, you could do that. Sorry, for some reason I had this vision of
>> you wanting the browser to render the file, as opposed to calling the
>> locally installed control. I really ought to think...:P
>>
>>
>> Rob Church
>>
>> On 27/09/05, Con Rodi <conrodi(a)vt.edu> wrote:
>>
>>> Not so. You need to change $wgFileExtensions in your
>>> localSettings.php to something like this...
>>> $wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'ogg',
>>> 'doc',
>>> 'pdf', 'txt', 'mov', 'wav' );
>>> That will allow you to upload pdfs. You will need to refer to them
>>> as images, though.
>>> [[Image:something.pdf]] will try to inline the pdf file. This may
>>> not work well in some browsers, and may slow down page loading in
>>> all
>>> browsers.
>>> [[:Image:something.pdf]] will create a link to the image page that
>>> actually holds the pdf. From there any browser can download the
>>> pdf.
>>> Similar details apply for word documents or others.
>>>
>>> Con
>>>
>>> On Sep 27, 2005, at 10:47 AM, Rob Church wrote:
>>>
>>>
>>>> PDF is a document, not an image format. As far as I know, there is
>>>> also no server-side control which would allow display of PDF
>>>> files, so
>>>> I have a nasty feeling the answer to both your questions is, "no".
>>>>
>>>>
>>>> Rob Church
>>>>
>>>> On 27/09/05, Bass, Joshua L <joshua.l.bass(a)lmco.com> wrote:
>>>>
>>>>
>>>>> I would like to allow PDF image uploads and for these to
>>>>> display as
>>>>> images.
>>>>> Is this possible? Is there a setting that controls this?
>>>>>
>>>>> _______________________________________________
>>>>> MediaWiki-l mailing list
>>>>> MediaWiki-l(a)Wikimedia.org
>>>>> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>>>>>
>>>>>
>>>>>
>>>> _______________________________________________
>>>> MediaWiki-l mailing list
>>>> MediaWiki-l(a)Wikimedia.org
>>>> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>>>>
>>>>
>>>
>>> _______________________________________________
>>> MediaWiki-l mailing list
>>> MediaWiki-l(a)Wikimedia.org
>>> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>>>
>>>
>> _______________________________________________
>> MediaWiki-l mailing list
>> MediaWiki-l(a)Wikimedia.org
>> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>>
>>
> _______________________________________________
> MediaWiki-l mailing list
> MediaWiki-l(a)Wikimedia.org
> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>
_______________________________________________
MediaWiki-l mailing list
MediaWiki-l(a)Wikimedia.org
http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
Hello i have a big problem:
(version in my own forum with screenshots
http://forum.darklevel.org/viewtopic.php?p=15195#15195)
i backup via phpmyadmin and everything seems to be fine ....
Than i try to import the sql file via phpmyadmin and getting first
trouble cause i have a 2mb limit but than i tried a diffrent host and
there i get a error 1071 - Specified key was too long; max key length is
1000 bytes
The third thing i tried is:
I set up an sql server at my workstation via xampp than than i created
via command line a new table and than i loaded the sql file in it.
I had a few errors but first everything look fine all 26 tables were
build ..... than i tried to acess the wiki and just the headlines are
there everything else is gone :-(
Greetz Stephan
I found the answer to one of my questions:
Put this in LocalSettings.php:
$wgFileExtensions = array( 'png', 'gif', 'jpg', 'jpeg', 'ogg', 'pdf',
'mov', 'mp3' );
I found that I can use <embed src='document.pdf>
-----Original Message-----
From: mediawiki-l-bounces(a)Wikimedia.org
[mailto:mediawiki-l-bounces@Wikimedia.org] On Behalf Of Rob Church
Sent: Tuesday, September 27, 2005 9:48 AM
To: MediaWiki announcements and site admin list
Subject: Re: [Mediawiki-l] Allow PDF uploads?
PDF is a document, not an image format. As far as I know, there is
also no server-side control which would allow display of PDF files, so
I have a nasty feeling the answer to both your questions is, "no".
Rob Church
On 27/09/05, Bass, Joshua L <joshua.l.bass(a)lmco.com> wrote:
> I would like to allow PDF image uploads and for these to display as
> images.
> Is this possible? Is there a setting that controls this?
>
> _______________________________________________
> MediaWiki-l mailing list
> MediaWiki-l(a)Wikimedia.org
> http://mail.wikipedia.org/mailman/listinfo/mediawiki-l
>
_______________________________________________
MediaWiki-l mailing list
MediaWiki-l(a)Wikimedia.org
http://mail.wikipedia.org/mailman/listinfo/mediawiki-l