-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
46 lines (40 loc) · 1.05 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
<?php
require_once 'bootstrap.php';
if ($config['project_list']) {
autoload('Medula\HTMLprototyper\HTMLprototyper');
autoload('Medula\HTMLprototyper\Project');
$HTMLprototyper = new Medula\HTMLprototyper\HTMLprototyper();
// Creación de nuevo proyecto
if (isset($_POST['projectName']))
{
$projectName = $_POST['projectName'];
$HTMLprototyper->newProject($projectName);
}
// Listado de proyectos
$projectsList = $HTMLprototyper->listProjects();
?>
<!doctype html>
<html lang="es">
<head>
<meta charset="utf-8">
<title>HTMLprototyper - <?php echo $config['company']; ?></title>
<meta http-equiv="x-ua-compatible" content="ie=edge, chrome=1">
</head>
<body>
<form method="post">
<input type="text" name="projectName" placeholder="Nombre proyecto">
<input type="submit">
</form>
<h1><?php echo $lang['project_list']; ?></h1>
<div>
<ul>
<?php
foreach ($projectsList as $project) {
echo '<li><a href="' . $HTMLprototyper::$projectsFolder . '/' . $project['1'] . '">' . $project['0'] . '</a></li>';
}
?>
</ul>
</div>
</body>
</html>
<?php } ?>