source: trunk/web/app/out/dist/content/set_artiste_downloads/e_add_download.php

Last change on this file was 6, checked in by dj3c1t, 12 years ago

mise a jour du trunk

File size: 3.8 KB
Line 
1<?php /* --------------------------------- ajouter un download */ ?>
2
3<h3>Ajouter un download</h3>
4<form name="download_ordre"
5      action="<?= $env->url(array("e" => "set_artiste_downloads", "artiste" => $env->out["artiste"]["id"], "action" => "add_download")) ?>"
6      method="post">
7  <input type="hidden" name="action" value="add_download" />
8  <table class="admin">
9        <tr>
10          <th>nom du download</th>
11          <td><input type="text" name="nom" value="<?= isset($_POST["nom"]) ? $_POST["nom"] : "" ?>" size="40"/></td>
12        </tr>
13        <tr>
14          <th>style</th>
15          <td><input type="text" name="style" value="<?= isset($_POST["style"]) ? $_POST["style"] : "" ?>" size="40"/></td>
16        </tr>
17        <tr>
18          <th>licence</th>
19          <td>
20            <select name="licence">
21<?php foreach($env->out["licences"] as $id => $values) : ?>
22              <option value="<?= $id ?>"<?= isset($_POST["licence"]) && $_POST["licence"] == $id ? " selected" : ""?>><?= $values["nom"] ?></option>
23<?php endforeach; ?>
24            </select><br />
25            <p class="info">Si vous utilisez une licence ouverte qui n'est pas dans la liste,
26            <a href="<?= $env->url(array("e" => "contact")) ?>">contactez-nous</a>.</p>
27          </td>
28        </tr>
29        <tr>
30          <th>date de cr&eacute;ation</th>
31          <td>
32<?php
33
34  $jour_creation = isset($_POST["jour_creation"]) ? $_POST["jour_creation"] : date("j");
35  $mois_creation = isset($_POST["mois_creation"]) ? $_POST["mois_creation"] : date("n");
36  $annee_creation = isset($_POST["annee_creation"]) ? $_POST["annee_creation"] : date("Y");
37
38?>
39            jour
40            <select name="jour_creation">
41<?php for($j = 1; $j <=31; $j++) : ?>
42              <option value="<?= strlen($j) == 1 ? "0".$j : $j ?>"<?= $jour_creation == $j ? " selected" : ""?>>
43                <?= strlen($j) == 1 ? "0".$j : $j ?>
44              </option>
45<?php endfor; ?>
46            </select>
47            mois
48            <select name="mois_creation">
49<?php for($m = 1; $m <=12; $m++) : ?>
50              <option value="<?= strlen($m) == 1 ? "0".$m : $m ?>"<?= $mois_creation == $m ? " selected" : ""?>>
51                <?= strlen($m) == 1 ? "0".$m : $m ?>
52              </option>
53<?php endfor; ?>
54            </select>
55            ann&eacute;e
56            <input type="text" size="4" name="annee_creation" value="<?= $annee_creation ?>">
57          </td>
58        </tr>
59        <tr>
60          <th>Album</th>
61          <td>
62<?php if($env->out["albums"]) : ?>
63            <select name="album">
64              <option value=""<?= $env->out["download"]["id_album"] ? "" : " selected" ?>>Aucun album</option>
65<?php foreach($env->out["albums"] as $id => $album) : ?>
66              <option value="<?= $id ?>"<?= $env->out["download"]["id_album"] == $id ? " selected" : ""?>><?= $album["titre"] ?></option>
67<?php endforeach; ?>
68            </select>
69<?php else : ?>
70            <p class="info">Vous n'avez inscrit aucun album pour le moment</p>
71<?php endif; ?>
72          </td>
73        </tr>
74        <tr>
75          <th>fichier</th>
76          <td>
77            format
78            <select name="format">
79<?php foreach($env->out["formats"] as $id => $values) : ?>
80              <option value="<?= $id ?>"<?= isset($_POST["format"]) && $_POST["format"] == $id ? " selected" : ""?>><?= $values["nom"] ?></option>
81<?php endforeach; ?>
82            </select>
83            url
84            <input type="text" name="url" value="<?= isset($_POST["style"]) ? $_POST["style"] : "" ?>" size="30"><br />
85            <p class="info">Vous pourrez, par la suite, ajouter des fichiers dans d'autres formats pour ce download</p>
86          </td>
87        </tr>
88        <tr>
89          <td colspan="2" align="right"><input type="submit" value="Ajouter le download" /></td>
90        </tr>
91  </table>
92</form>
Note: See TracBrowser for help on using the repository browser.