aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManuel Hiebel <leuhmanu@mageia.org>2018-02-20 10:25:09 +0100
committerManuel Hiebel <leuhmanu@mageia.org>2018-02-20 10:25:09 +0100
commit6e44a9eb31786818eb868f63c649283244cc3646 (patch)
treee7b64342d0eac5f60c5c7ff6467c37b663055152
parentf62c24a63ec3eaa2fcf7e50d8eb2590aaba26321 (diff)
downloadwww-6e44a9eb31786818eb868f63c649283244cc3646.tar
www-6e44a9eb31786818eb868f63c649283244cc3646.tar.gz
www-6e44a9eb31786818eb868f63c649283244cc3646.tar.bz2
www-6e44a9eb31786818eb868f63c649283244cc3646.tar.xz
www-6e44a9eb31786818eb868f63c649283244cc3646.zip
draft for a download page for all isos
-rw-r--r--en/downloads/alt.php102
1 files changed, 102 insertions, 0 deletions
diff --git a/en/downloads/alt.php b/en/downloads/alt.php
new file mode 100644
index 000000000..b90c87b84
--- /dev/null
+++ b/en/downloads/alt.php
@@ -0,0 +1,102 @@
+<?php
+
+$stableVersion = '6';
+$cauldron = '7';
+
+define('HLANG', true);
+
+require '../../langs.php';
+$dictionary = read_translation_file($locale, array('cauldron', 'common_footer'));
+
+?>
+<!DOCTYPE html>
+<html dir="ltr" lang="<?php echo $locale; ?>">
+<head>
+ <meta charset="utf-8">
+ <title><?php echo sprintf(_g('Download').' '. ' Mageia')?></title>
+ <meta name="robots" content="index,nofollow,nosnippet">
+ <?php echo common_header(); ?>
+ <?php include '../../analytics.php'; ?>
+</head>
+<body class="release downloads">
+ <?php echo $hsnav; ?>
+
+ <h1 id="mgnavt"><?php echo sprintf(_g('Download') . ' Mageia');?></h1>
+
+
+<div id="doc">
+
+<div class="para">
+ <p>
+ <?php _g('Mageia is provided as ISO image files that have to be written to blank <a href="%s">CD or DVD discs</a>.', array(_r('https://wiki.mageia.org/en/Writing_CD_and_DVD_images')), ' '); ?>
+ <br>
+ <?php _g('All ISOs can also be launched from a <a %s>USB drive</a>.', array('href="' . _r('https://wiki.mageia.org/en/Installation_Media#Dump_Mageia_ISO_on_a_USB_flash_drive') . '"'));
+ echo '</p>';
+ _g('To <a %s>dump</a> a Mageia installation ISO on a USB stick, you may try one of several tools:', array(''),'p');
+ echo '<ul><li>';
+ _g('For Linux, IsoDumper, available inside repo. Or any tools based on %sdd%s.', array('<span class="italic" >', '</span>'), ' ');
+ _g('Unetbootin is not supported.', null, 'span class="warn"'); ?>
+ </li>
+ <?php _g('For Windows please have a look on our <a href="%s">wiki</a> for your options.', array(_r('https://wiki.mageia.org/en/Dump_Mageia_ISO_on_a_USB_flash_drive_-_Alternative_tools')), 'li'); ?>
+ </ul>
+ <div id="iso2usbEx" class="popover-content"><p>
+ <?php _g('"Dumping" an image onto a flash device destroys any prior file-system in the partition; access to any data not destroyed will be lost, and partition capacity will be reduced to the image size. In other words, all prior data on the device is at risk.'); ?>
+ </p></div>
+ <p>
+ <?php _g('If you have <a href="%s">UEFI</a>, a procedure is available in the <a href="%s">wiki</a>.', array(_r('http://en.wikipedia.org/wiki/Unified_Extensible_Firmware_Interface'),_r('https://wiki.mageia.org/en/Installing_on_systems_with_UEFI_firmware' /*this will be changed to tooltip, so no more url*/))) ;?>
+ </p>
+</div>
+
+<?php
+
+$ini = parse_ini_file('get/definitions.ini', true);
+$ini = array_reverse($ini);
+
+function doTheTable($url, $name, $torrent, $magnet, $size){
+ $table = sprintf('<tr scope="row"><td><a href="get/?q=%s">%s</a></td>',$url, $name);
+ $table .= sprintf('<td><a href="./get/?q=%s&amp;torrent=1">%s</a></td>',$url , $torrent ? 'torrent': '');
+ $table .= sprintf('<td><a href="%s">%s</a></td>',$magnet , $magnet ? 'magnet': '');
+ $table .= sprintf('<td>%s</td></tr>'. PHP_EOL, $size);
+ return $table;
+};
+
+foreach ($ini as $section => $values) {
+$version = $values['name'][7];
+$name = $values['name'];
+$torrent = $values['torrent'];
+$magnet = $values['magnet'];
+$size = $values['size'];
+
+if ($version == $stableVersion){
+ $tables .= doTheTable($section, $name, $torrent, $magnet, $size);
+}elseif ($version == $cauldron){
+ $tablec .= doTheTable($section, $name, $torrent, $magnet, $size);
+}else{
+ $tablea .= doTheTable($section, $name, $torrent, $magnet, $size);
+}
+};
+
+function allDiv($version, $table, $show){
+
+ $div = sprintf('<div class="card"><div class="card-header" id="heading%s">', $version);
+ $div .= sprintf('<button class="btn btn-outline-secondary" data-toggle="collapse" data-target="#collapse%s" aria-expanded="true" aria-controls="collapse%s">%s</button></div>'. PHP_EOL,$version, $version, $version);
+ $div .= sprintf('<div id="collapse%s" class="collapse %s" aria-labelledby="heading%s" data-parent="#accordion"><div class="card-body">' . PHP_EOL, $version, $show, $version);
+ $div .= '<table class="table table-hover table-sm">';
+ $div .= sprintf('<thead><tr><th scope="col">iso</th><th>torrent</th><th>magnet</th><th>size</th></tr></thead>' . PHP_EOL);
+ $div .= sprintf('<tbody>%s</tbody></table>' . PHP_EOL, $table);
+ echo $div . '</div></div></div>'. PHP_EOL;
+}
+
+
+echo '<div id="accordion">';
+
+allDiv('Stable', $tables, 'show');
+allDiv('Unstable', $tablec);
+allDiv('Archives', $tablea);
+
+?>
+</div>
+</div>
+<?php echo common_footer($locale); ?>
+</body>
+</html>