Index: trunk/extensions/DoubleWiki/DoubleWiki.php |
— | — | @@ -92,7 +92,7 @@ |
93 | 93 | |
94 | 94 | #do the job |
95 | 95 | $text = matchColumns ( $text, $myLanguage, $myURL , |
96 | | - $translation, $languageName, $url ); |
| 96 | + $translation, $languageName, $url, $wgContLanguageCode, $match_request ); |
97 | 97 | } |
98 | 98 | return true; |
99 | 99 | } |
— | — | @@ -106,7 +106,7 @@ |
107 | 107 | * Text is split into slices based on title tags |
108 | 108 | */ |
109 | 109 | |
110 | | -function matchColumns( $left_text, $left_title, $left_url, $right_text, $right_title, $right_url ){ |
| 110 | +function matchColumns( $left_text, $left_title, $left_url, $right_text, $right_title, $right_url, $left_lang_code, $right_lang_code ){ |
111 | 111 | |
112 | 112 | # note about emdedding: |
113 | 113 | # text is split only at a single level. |
— | — | @@ -251,12 +251,12 @@ |
252 | 252 | if( ( ($left_nesting == $left_splitlevel) |
253 | 253 | && ($right_nesting == $right_splitlevel) ) || $the_end) { |
254 | 254 | $body .= |
255 | | - "<tr><td valign=\"top\" style=\"padding-right: 0.5em\">" |
| 255 | + "<tr><td valign=\"top\" style=\"padding-right: 0.5em\" lang=\"{$left_lang_code}\">" |
256 | 256 | ."<div style=\"width:35em; margin:0px auto\">\n" |
257 | 257 | .$left_prefix.$left_bits[$l].$left_suffix |
258 | 258 | ."</div>" |
259 | 259 | |
260 | | - ."</td>\n<td valign=\"top\" style=\"padding-left: 0.5em\">" |
| 260 | + ."</td>\n<td valign=\"top\" style=\"padding-left: 0.5em\" lang=\"{$right_lang_code}\">" |
261 | 261 | ."<div style=\"width:35em; margin:0px auto\">\n" |
262 | 262 | .$right_prefix.$right_bits[$l].$right_suffix |
263 | 263 | ."</div>" |
— | — | @@ -286,9 +286,9 @@ |
287 | 287 | $head = |
288 | 288 | "<table width=\"100%\" border=\"0\" bgcolor=\"white\" rules=\"cols\" cellpadding=\"0\"> |
289 | 289 | <colgroup><col width=\"50%\"/><col width=\"50%\"/></colgroup><thead> |
290 | | -<tr><td bgcolor=\"#cfcfff\" align=\"center\"> |
| 290 | +<tr><td bgcolor=\"#cfcfff\" align=\"center\" lang=\"{$left_lang_code}\"> |
291 | 291 | <a href=\"{$left_url}\">{$left_title}</a></td> |
292 | | -<td bgcolor=\"#cfcfff\" align=\"center\"> |
| 292 | +<td bgcolor=\"#cfcfff\" align=\"center\" lang=\"{$right_lang_code}\"> |
293 | 293 | <a href=\"{$right_url}\" class='extiw'>{$right_title}</a> |
294 | 294 | </td></tr></thead>\n"; |
295 | 295 | return $head.$body."</table>" ; |