diff options
author | filip <filip.komar@gmail.com> | 2020-10-28 15:01:26 +0100 |
---|---|---|
committer | filip <filip.komar@gmail.com> | 2020-10-28 15:01:26 +0100 |
commit | 905f284262663df6a0974d06f8a1a33dda17cea5 (patch) | |
tree | be681aa86c10f8fe5f374c5153f0d9d61618037f /en/4 | |
parent | 3460f073747b4955e1a65deb1f716c691e637c43 (diff) | |
download | www-905f284262663df6a0974d06f8a1a33dda17cea5.tar www-905f284262663df6a0974d06f8a1a33dda17cea5.tar.gz www-905f284262663df6a0974d06f8a1a33dda17cea5.tar.bz2 www-905f284262663df6a0974d06f8a1a33dda17cea5.tar.xz www-905f284262663df6a0974d06f8a1a33dda17cea5.zip |
adding RTL support for mga4 pages
Diffstat (limited to 'en/4')
-rw-r--r-- | en/4/download_index.php | 45 | ||||
-rw-r--r-- | en/4/index.php | 3 |
2 files changed, 25 insertions, 23 deletions
diff --git a/en/4/download_index.php b/en/4/download_index.php index f0f1260d0..120d6fe77 100644 --- a/en/4/download_index.php +++ b/en/4/download_index.php @@ -6,6 +6,7 @@ define('ALIGNMENT', 'Center'); require '../../langs.php'; $dictionary = read_translation_file($locale, array('4', 'common_footer')); require '../downloads/get/lib.php'; +$rtl = is_locale_rtl($locale); function get_mageia_image_file_name($variant = null, $arch, $medium, $ext) { @@ -42,7 +43,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un ?> <!DOCTYPE html> -<html dir="ltr" lang="<?php echo $locale; ?>"> +<html <?php echo $rtl ? 'dir="rtl"' : 'dir="ltr"'?> lang="<?php echo $locale; ?>"> <head> <meta charset="utf-8"> <title><?php echo sprintf(_r('Download') . ' Mageia 4.1')?></title> @@ -54,11 +55,11 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un <?php echo common_header(); ?> <?php include '../../analytics.php'; ?> </head> -<body class="release downloads"> +<body class="release downloads" <?php echo $rtl ? 'style="text-align: right;"' : ''?>> <?php echo $hsnav; ?> <h1 id="mgnavt"><?php echo sprintf(_r('Download') . ' <strong>Mageia 4.1</strong>')?></h1> <?php include '../4/nav.php'; ?> - <div id="doc4" class="yui-t7" style="margin-bottom: 0px;"> + <div id="doc4" class="yui-t7" style="margin-bottom: 0px; <?php echo $rtl ? 'text-align: right;"' : ''?>"> <div id="bd" role="main"> <div class="yui-ge bb1"> <div class="yui-u first rb1"> @@ -73,15 +74,15 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un <table class="fr-table dlt2"> <thead> <tr> - <th><?php _g('Format');?></th> - <th class="size"><?php _g('size');?></th> - <th><?php _g('link');?></th> - <th><?php _g('BitTorrent');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('Format');?></th> + <th<?php echo $rtl ? ' style="text-align: right;"' : ' class="size"'?>><?php _g('size');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('link');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('BitTorrent');?></th> </tr> </thead> <tbody> <tr> - <th class="name" style="width:60%">DVD 32bit<br>DVD 64bit<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name" style="width:60%">DVD 32bit<br>DVD 64bit<br> <span class="dlinfo"><?php _g('Desktop'); ?>: GNOME, KDE, XFCE, Mate, Cinnamon, LXDE, ...</span></th> <td class="size">3.7GB</td> <td> @@ -95,7 +96,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un </td> </tr> <tr> - <th class="name">DVD dualarch<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name">DVD dualarch<br> <span class="dlinfo"><?php _g('Desktop'); ?>: XFCE</span></th> <td class="size">1GB</td> <td> @@ -131,15 +132,15 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un <table class="fr-table dlt2"> <thead> <tr> - <th><?php _g('Desktop');?></th> - <th class="size"><?php _g('size');?></th> - <th><?php _g('link');?></th> - <th><?php _g('BitTorrent');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('Desktop');?></th> + <th<?php echo $rtl ? ' style="text-align: right;"' : ' class="size"'?>><?php _g('size');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('link');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('BitTorrent');?></th> </tr> </thead> <tbody> <tr> - <th class="name" style="width:60%">LiveDVD KDE<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name" style="width:60%">LiveDVD KDE<br> <span class="dlinfo"><?php _g('All languages')?></span></th> <td class="size">1.4GB</td> <td> @@ -153,7 +154,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un </td> </tr> <tr> - <th class="name">LiveDVD GNOME<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name">LiveDVD GNOME<br> <span class="dlinfo"><?php _g('All languages')?></span></th> <td class="size">1.4GB</td> <td> @@ -166,7 +167,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un dl_link('LiveDVD-GNOME','x86_64','DVD',true);?> </td> <tr> - <th class="name">LiveCD KDE<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name">LiveCD KDE<br> <span class="dlinfo"><?php _g('English only')?></span></th> <td class="size">700MB</td> <td> @@ -176,7 +177,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un </td> </tr> <tr> - <th class="name">LiveCD GNOME<br> + <th<?php echo $rtl ? ' class="size"' : ''?> class="name">LiveCD GNOME<br> <span class="dlinfo"><?php _g('English only')?></span></th> <td class="size">700MB</td> <td> @@ -197,14 +198,14 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un <table class="fr-table dlt2"> <thead> <tr> - <th><?php _g('Format');?></th> - <th class="size"><?php _g('size');?></th> - <th><?php _g('link');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('Format');?></th> + <th<?php echo $rtl ? ' style="text-align: right;"' : ' class="size"'?>><?php _g('size');?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('link');?></th> </tr> </thead> <tbody> <tr> - <th><?php _g('Network installer, Free Software CD')?></th> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('Network installer, Free Software CD')?></th> <td class="size">27MB<br>53MB</td> <td><?php dl_link('Boot','i586','CD',false); echo '<br>'; @@ -212,7 +213,7 @@ function dl_link($variant = null, $arch = 'i586', $medium, $torrent = false, $un </td> </tr> <tr> - <th><?php _g('Network installer + nonfree firmware CD')?><br> + <th<?php echo $rtl ? ' class="size"' : ''?>><?php _g('Network installer + nonfree firmware CD')?><br> <span class="dlinfo"><?php _g('needed for some disc controllers, some network cards, etc.')?></span></th> <td class="size">37MB<br>74MB</td> <td><?php dl_link('Boot-nonfree','i586','CD',false); diff --git a/en/4/index.php b/en/4/index.php index ac3d499d3..09de355a1 100644 --- a/en/4/index.php +++ b/en/4/index.php @@ -2,11 +2,12 @@ define('HLANG', true); define('ALIGNMENT', 'Center'); require '../../langs.php'; +$rtl = is_locale_rtl($locale); $dictionary = read_translation_file($locale, array('4', 'common_footer')); ?> <!DOCTYPE html> -<html lang="<?php echo $locale; ?>"> +<html <?php echo $rtl ? 'dir="rtl"' : 'dir="ltr"'?> lang="<?php echo $locale; ?>"> <head> <meta charset="utf-8"> <title><?php _g('Mageia 4')?></title> |