Page MenuHomePhabricator

render a text and its translation, on two columns
Closed, ResolvedPublic

Assigned To
None
Authored By
bzimport
Nov 28 2005, 8:42 PM
Referenced Files
F2475: patch
Nov 21 2014, 8:58 PM
F2474: patch1
Nov 21 2014, 8:57 PM
F2473: patch2
Nov 21 2014, 8:57 PM
F2472: patch
Nov 21 2014, 8:57 PM
F2471: DoubleWiki.php
Nov 21 2014, 8:57 PM

Description

Author: thomasV1

Description:
this patch displays an article and its translation on the same page, on two
columns. the translation is supposed to be accessible through an
interlanguage link.

the patch was primarily written for Wikisource, although other projects might
find it useful.


Version: unspecified
Severity: enhancement
URL: http://thecircle.dyndns.org/wiki/index.php/Culture_Libre_-_Pr%C3%A9face?match=ro

Details

Reference
bz4104

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 8:57 PM
bzimport set Reference to bz4104.
bzimport added a subscriber: Unknown Object (MLST).

thomasV1 wrote:

patch: diff from cvs

attachment patch ignored as obsolete

Very ugly hack!

Should:

  1. be an extension
  2. use action=render
  3. be careful about which interwikis are allowed (security issues?)

thomasV1 wrote:

thanks for your feedback.

1: I made it an extension, but I had to add new hooks to Outputpages.php. I
think that I cannot use the existing hooks in Parser.php, because of the cache.
Is that a problem?

2: done

3: Interwikis are defined by the admin of the wiki. I am not sure if there is a
way to control that. any suggestion?

thomasV1 wrote:

extension file

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

diff from cvs, OutputPage.php

attachment patch ignored as obsolete

thomasV1 wrote:

extension file, corrected after brion's feedback

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

extension file, new version after Brion's comments

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

extension file

improved some regular expressions, added matching of h2 and h3 subtitles

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

extension file

Now generates valid html, assuming that input pages are themselves valid.

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

extension file, fixed null test

attachment ShowTranslation.php ignored as obsolete

thomasV1 wrote:

could some developer review/commit this code?
apparently brion is too busy with other
things, he said he has no time.

I have been waiting for quite some time,
and I do not know to whom I should ask.

what should I do?

thomasV1 wrote:

extension file

minor fixes

Attached:

thomasV1 wrote:

cvs diff -u OutputPage.php

You did not commit the patch for OutputPage.php. It adds a hook used by the
extension.

Here is an updated version of the patch, since recent changes to OutputPage.php
deprecate the previous one.

attachment patch ignored as obsolete

thomasV1 wrote:

cvs diff -u OutputPage.php

attachment patch ignored as obsolete

thomasV1 wrote:

cvs diff -u docs/hooks.txt

Attached:

As discussed in chat, the hook isn't quite right; breaks when parser cache is not used.

thomasV1 wrote:

cvs diff -u OutputPage.php

Attached:

thomasV1 wrote:

cvs diff -u Article.php

call AddPrimaryWikiText instead of AddWikiText

Attached:

thomasV1 wrote:

cvs diff -u DoubleWiki.php

debugging code

attachment patch ignored as obsolete

thomasV1 wrote:

cvs diff -u DoubleWiki.php

oops

Attached:

gangleri wrote:

changing url to include match=foo

thomasV1 wrote:

works. thanks, brion!