Hi,
Is there a function that already exists in the codebase that returns
the # of sections in an article? I can't seem to find it.
article::getSection takes a parameter for the ith section, but if you
want to iterate over an article searching for a particular section,
it's not clear how many sections there are. Similarily, it'd be great
to have a function that return the section based on the section name,
like getSectionByName or similar.
Travis
Hello,
Please compare
http://commons.wikimedia.org/w/index.php?title=Special:Userlogin&uselang=he…
to
http://he.wikipedia.org/w/index.php?title=Special:Userlogin&uselang=he&type…
On Commons, the messages appear RTL text direction which is correct,
but on the left, which I imagine is as unnatural as right-aligning for
English.
Evidently there is some sitewide setting for he.wp that tells it to
display messages right aligned. Commons default language is English
which is left aligned. I guess that using uselang=he is not enough for
it to display messages right aligned?
Should we (Commons) go and insert <span align="right"> around every /he message?
Would this solve it?
(Would this be a *good way* to solve it?)
thanks,
Brianna
user:pfctdayelise
An automated run of parserTests.php showed the following failures:
This is MediaWiki version 1.10alpha (r20077).
Reading tests from "maintenance/parserTests.txt"...
Reading tests from "extensions/Cite/citeParserTests.txt"...
Reading tests from "extensions/Poem/poemParserTests.txt"...
18 still FAILING test(s) :(
* URL-encoding in URL functions (single parameter) [Has never passed]
* URL-encoding in URL functions (multiple parameters) [Has never passed]
* TODO: Table security: embedded pipes (http://mail.wikipedia.org/pipermail/wikitech-l/2006-April/034637.html) [Has never passed]
* TODO: Link containing double-single-quotes '' (bug 4598) [Has never passed]
* TODO: message transform: <noinclude> in transcluded template (bug 4926) [Has never passed]
* TODO: message transform: <onlyinclude> in transcluded template (bug 4926) [Has never passed]
* BUG 1887, part 2: A <math> with a thumbnail- math enabled [Has never passed]
* TODO: HTML bullet list, unclosed tags (bug 5497) [Has never passed]
* TODO: HTML ordered list, unclosed tags (bug 5497) [Has never passed]
* TODO: HTML nested bullet list, open tags (bug 5497) [Has never passed]
* TODO: HTML nested ordered list, open tags (bug 5497) [Has never passed]
* TODO: Inline HTML vs wiki block nesting [Has never passed]
* TODO: Mixing markup for italics and bold [Has never passed]
* TODO: 5 quotes, code coverage +1 line [Has never passed]
* TODO: dt/dd/dl test [Has never passed]
* TODO: Images with the "|" character in the comment [Has never passed]
* TODO: Parents of subpages, two levels up, without trailing slash or name. [Has never passed]
* TODO: Parents of subpages, two levels up, with lots of extra trailing slashes. [Has never passed]
Passed 493 of 511 tests (96.48%)... 18 tests failed!
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
What would have to be done to enable FLAC uploads to Wikimedia projects?
This sort of support would be useful for things like "Spoken Wikipedia"
projects, where as of right now there is no way of uploading a lossless
version of the audio file for other people to edit. FLAC is a
free/open-source codec.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFF5NK1qTO+fYacSNoRAkfKAJsFqc1RcKnGaWuSLWrHHAoIu9zSfACdHfFT
xsYjZiJ7CQABkdzndWe4218=
=U0Qp
-----END PGP SIGNATURE-----
Right now on the English Wikipedia bots are limited to 6 edits per minute.
Is it time to raise the permitted edit rate? Do we have the server capacity
now to handle rapid editing?
--Mets501
I got mwdumper to work, but IMHO it still a very broken utility. I
worked on it for some time and discovered the voodoo sequence on Linux to
get it working. I went ahead and was bold and updated the meta pages
with some useful advice for others who run into these problems. As I
previously suggested, I think it would be a good idea to improve the
quality of these tools since they do not work properly with released
MediaWiki Distributions and published XML dumps provide from Wikipedia
with A LOT of work and debugging.
I have updated meta here:
http://meta.wikimedia.org/wiki/Data_dumps
Jeff
I'm trying to use the database functions to connect to an external
database called wikibox_db using the following
$dbr =& wfGetDB( DB_SLAVE );
$dbr->debug(true);
$dbr->selectDB('wikibox_db');
$output .= "\n\nQuery:".$dbr->lastQuery()."<br>\n\n";
$res = $dbr->select(
'wikibox_db.box',
'*'
);
This gives the following error on the special page I'm working on:
A database query syntax error has occurred. This may indicate a bug
in the software. The last attempted database query was:
(SQL query hidden)
from within function "Database::select". MySQL returned error "1103:
Incorrect table name 'wikibox_db.box' (jim-hus-computer.local)".
Not surprisingly, it works if I query a table in the mediawiki
schema. Two questions:
1) Anyone know how to do this?
2) How do I set the wiki to not hide the sql query from me?
Thanks!
Jim
=====================================
Jim Hu
Associate Professor
Dept. of Biochemistry and Biophysics
2128 TAMU
Texas A&M Univ.
College Station, TX 77843-2128
979-862-4054
David A. Desrosiers wrote:
>I must have imported enwiki 3-dozen times over the last two weeks on two
>physically separate machines. I've been thoroughly testing raw import
>speed with mwdumper/MySQL under BSD 6.2 with/without DMA enabled, IDE
>drives, SATA drives, and a myriad of other combinations.
>
>
Different OS. I am running Linux with FedoraCore 5. I think its
related to
java incompatibility and/or mysql issues with Federal Core 5. The php-mysql
and a lot of other subsystems were changed in the Linux distros due to
licensing
issues with the MySQL code moving forward.
>
>It works great. You're doing something wrong if it isn't working.
>
>
That's a stretch to say, since we are dealing with different OS's. I
have purged out
the endb database completely and I am re-running the entire mwdumper
test with Rob's
UPDATE suggestions again. The previous database had data leftover from
an importDump.php
run. After the test completes, I will post the results. I am farily
certain mwdumper has some
incompatiblity problems with the stock Linux Distributions as it has
been reported in a lot of places.
Since more people run Linux than BSD at present, it bears looking into
and getting fixed
and/or understood. I am happy to devote time to getting to the bottom
of it for Rob
and Brion.
Jeff
>
>
>
On 27/02/07, travis(a)svn.wikimedia.org <travis(a)svn.wikimedia.org> wrote:
> Revision: 20069
> Author: travis
> Date: 2007-02-27 07:47:24 -0800 (Tue, 27 Feb 2007)
>
> Log Message:
> -----------
> change title to ititle to work out kinks with 1.9.3
Please note that it's better to work with the WebRequest class (a
global instance of which exists as $wgRequest) for obtaining GET and
POST data, since it contains functions which strip out PHP's "helpful"
behaviour such as magic_quotes and other nonsense.
Rob Church
Sorry, I fat fingered the email address and posted to the wrong list.
Here's the results of my testing.
Hi Rob,
I completed running mwdumper with the following command last night. It
took several hours to complete. I aborted the previous
importDump.php in order to run this test for you. The wiki they were
run against was en.wikigadugi.org. The database name is
endb.
[root@gadugi archive]#
[root@gadugi archive]#
[root@gadugi archive]#
[root@gadugi archive]#
[root@gadugi archive]# java -jar mwdumper.jar --format=sql:1.5
/wikidump/dump/enwiki-GFDL-20070206-pages-articles.xml | mysql -u root
-p endb
Enter password:
[root@gadugi archive]#
[root@gadugi archive]#
[root@gadugi archive]#
[root@gadugi archive]#
The mwdumper ran to completion through almost 4 million articles then
exited. I then applied the command you had specified. Same result,
mwdumper does not work as was previously reported on other blogs. I am
running Fedora Core 5 on wikigadugi. Configuration has already
been provided in previous posts. Here is the output from applying the
UPDATE command via mysql.
[root@gadugi /]#
[root@gadugi /]# mysql -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 30734 to server version: 5.0.18
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> use endb
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> UPDATE page SET page_touched = 20070226080700
-> ;
Query OK, 61932 rows affected (2.72 sec)
Rows matched: 61932 Changed: 61932 Warnings: 0
mysql>
mysql>
mysql>
The server is at http://en.wikigadugi.org and as you can see if you
visit the site, mwdumper fails to update any of the articles to the
database (other than filling the mysql Innodb file with a lot of wasted
space).
:-)
Jeff