Project

General

Profile

Revision 7f9aab46

Added by Victor Pongnian almost 11 years ago

Version réaliée pour la sage de Victor Pongnian

View differences:

index.php
3 3
<head>
4 4
  <meta http-equiv="Content-type" content="text/html; charset=UTF-8"/>
5 5
  <title>Liste des panoramas</title>
6
  <link rel="stylesheet" media="screen" href="css/all.css" />
6
  <link rel="stylesheet" media="screen" href="css/index_style.css" />
7 7
  <script src="js/pano.js"></script>
8 8
</head>
9 9
<body>
10
  <h1>Liste des panoramas</h1>   
11
  <?php
12
   require 'class/site_point.class.php';
13
   require 'class/sites_dir.class.php';
14
   echo '<ul>';
15
   if(isset($_GET['dir']) && is_dir($_GET['dir'])) {
16
     $base_dir = $_GET['dir'];
17
   } else {
18
     $base_dir = 'tiles';
19
   }
20

  
21
   $dir = new sites_dir($base_dir);
22

  
23
   foreach($dir->get_sites() as $pt) {
24
     $params = $pt->get_params();
25
     if (isset($params['titre'])) {
26
       $cmt = $params['titre'];
27
     } else {
28
       $cmt = sprintf('fichier <samp>%s/%s</samp>', $pt->get_name(), $pt->get_prefix());
29
     }
30
     printf ('<li><a href="panorama.php?dir=%s&amp;panorama=%s">%s</a></li>'."\n", $base_dir, $pt->get_name(), $cmt);
31
   }
32
   echo '</ul>';
33
  ?>
10
	<img id="top" src="images/top.png" alt="">
11
	<div id="index_container">
12
		<h1><img src="images/tetaneutral.png" /></h1>
13
	  	<h2>Liste des panoramas</h2>
14
		   <?php
15
		  
16
		   require 'class/site_point.class.php';
17
		   require 'class/sites_dir.class.php';
18
		   
19
		   echo '<div id="containerList">';
20
		   echo '<ul>';
21
		 
22
		   if(isset($_GET['dir']) && is_dir($_GET['dir'])) {
23
		     $base_dir = $_GET['dir']; 
24
		   } else {
25
		    $base_dir='tiles';
26
		   }
27
		   
28
		   $dir = new sites_dir($base_dir);
29
		 
30
		   
31
		   foreach($dir->get_sites() as $pt) {
32
		   
33
		     $params = $pt->get_params();
34
		     if (isset($params['titre'])) {
35
		       $cmt = $params['titre'];
36
		      
37
		     } else {
38
		       $cmt = sprintf('fichier <samp>%s/%s</samp>', $pt->get_name(), $pt->get_prefix());
39
		     }
40
		     
41
		     printf ('<li><a href="panorama.php?dir=%s&amp;panorama=%s">%s</a></li>'."\n", $base_dir, $pt->get_name(), $cmt);
42
		   }
43
		   ?>
44
		</div>
45
	</div>
46
   <div id="interaction">
47
   
48
   <li><a href="./envoyer.php" title="Envoyer une image sur le site">Ajouter un panorama</a></li>
49
   <li><a href="./creerPano.php" title="Générer un panorama à partir d\'une image déjà envoyée">Générer un panorama</a></li>
50
 
51
   </div>
52
   </ul>
53
 <img id="bottom" src="images/bottom.png" alt="">
34 54
  <p><a href="http://validator.w3.org/check?uri=referer">page xHTML validé !</a></p>
35 55
</body>
36 56
</html>

Also available in: Unified diff