Subversion Repositories eFlore/Archives.eflore-consultation-v2

Rev

Rev 3 | Rev 11 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3 Rev 5
Line 17... Line 17...
17
// |                                                                                                      |
17
// |                                                                                                      |
18
// | You should have received a copy of the GNU Lesser General Public                                     |
18
// | You should have received a copy of the GNU Lesser General Public                                     |
19
// | License along with this library; if not, write to the Free Software                                  |
19
// | License along with this library; if not, write to the Free Software                                  |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
20
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
21
// +------------------------------------------------------------------------------------------------------+
21
// +------------------------------------------------------------------------------------------------------+
22
// CVS : $Id: eflore_photo.inc.php,v 1.1 2004-06-17 13:23:16 linda Exp $
22
// CVS : $Id: eflore_photo.inc.php,v 1.2 2004-06-17 15:19:26 linda Exp $
23
/**
23
/**
24
* Titre
24
* Titre
25
*
25
*
26
* Description
26
* Description
27
*
27
*
Line 30... Line 30...
30
//Auteur original :
30
//Auteur original :
31
*@author        linda ANGAMA<linda_angama@yahoo.fr>
31
*@author        linda ANGAMA<linda_angama@yahoo.fr>
32
//Autres auteurs :
32
//Autres auteurs :
33
*@author        Aucun
33
*@author        Aucun
34
*@copyright     Tela-Botanica 2000-2004
34
*@copyright     Tela-Botanica 2000-2004
35
*@version       $Revision: 1.1 $ $Date: 2004-06-17 13:23:16 $
35
*@version       $Revision: 1.2 $ $Date: 2004-06-17 15:19:26 $
36
*/
36
*/
Line 37... Line -...
37
 
-
 
38
session_start();
-
 
39
$res="";
-
 
Line 40... Line -...
40
$res.="<HTML><HEAD><link rel=\"stylesheet\" type=\"text/css\" media=\"screen\" href=\"photo.css\" /></HEAD><BODY>";
-
 
41
 
37
 
Line -... Line 38...
-
 
38
 
-
 
39
$res="";
-
 
40
 
42
error_reporting(E_ALL);
41
GEN_stockerStyleExterne('photo', GEN_CHEMIN_CLIENT.'eflore/presentations/styles/photo.css');
43
include_once "DB.php";
42
$deb=$_GET['deb'];
44
 
43
$agrandit=$_GET['agrandit'];
45
if (isset($agrandit))
44
if (isset($agrandit))
46
{
45
{
47
$res.="<div align=\"center\">";
46
$res.="<div align=\"center\">";
48
$res.="<p><a href=\"photo.php?".SID."&deb=".$_SESSION['dep']."\">Retour &agrave la miniature</a></p>";
-
 
49
$res.="<img src=\"".$agrandit."\"></div>";
47
$res.="<p><a href=\"eflore_photo.inc.php?".SID."&deb=".$_SESSION['dep']."\">Retour &agrave la miniature</a></p>";
-
 
48
$res.="<img src=\"".$agrandit."\"></div>";
50
unset($agrandit);
49
unset($agrandit);
-
 
50
}
51
echo $res;
51
else
52
}
-
 
53
 
52
{
54
$_SESSION['dep']=$deb;
53
if (!isset($deb)){$deb=0;}
55
echo $deb;
-
 
56
$path_rdf="/home/linda/Documents/testphp/rdf/";
54
$_SESSION['dep']=$deb;
57
$sep="\"\n";
55
$path_rdf="/home/linda/Documents/testphp/rdf/";
58
if (!isset($deb)){$deb=0;}
56
$sep="\"\n";
Line 59... Line 57...
59
$img_pg=6;
57
$img_pg=6;
Line 82... Line 80...
82
 
80
 
83
 
81
 
84
//requete sql 
82
//requete sql 
-
 
83
$req="select * from images";
85
$req="select * from images";
84
$cond="where identifier<=7";
86
$cond="where identifier<=7";
85
$requete="select count('identifier') from images ";
87
if(!$cond=="")
86
if(!$cond=="")
88
{
87
{
-
 
88
	$resultat=$db->query($req." ".$cond);
89
	$resultat=$db->query($req." ".$cond);
89
	$cpt=$db->query("select count('identifier') from images ".$cond);
90
	$cpt=$db->query("select count('identifier') from images ".$cond);
90
    echo $requete.$cond;
91
	$nbre_ligne=$cpt->fetchRow(DB_FETCHMODE_ORDERED);
91
	$nbre_ligne=$cpt->fetchRow(DB_FETCHMODE_ORDERED);
92
	print("nombre de lignes r&eacutesultat de la requ&ecircte : ".$nbre_ligne[0]."<br>");
92
	print("nombre de lignes r&eacutesultat de la requ&ecircte : ".$nbre_ligne[0]."<br>");
93
}
93
}
Line 129... Line 129...
129
		$res.="<area shape=\"rect\" coords=\"0,0,175,175\" href=\"gde_photo.php?agrandit=".$url_img."&".SID."\">";
129
		$res.="<area shape=\"rect\" coords=\"0,0,175,175\" href=\"gde_photo.php?agrandit=".$url_img."&".SID."\">";
130
		$res.="</map>";
130
		$res.="</map>";
131
		$res.="<img src=\"".$url_img_mini."\" border=0 usemap=\"#mini".$url_img."\">";
131
		$res.="<img src=\"".$url_img_mini."\" border=0 usemap=\"#mini".$url_img."\">";
132
		$res.="<p>num_ligne : ".$num_ligne."  id:  ".$ligne[0]."->".$ligne[1]."</p></div>";
132
		$res.="<p>num_ligne : ".$num_ligne."  id:  ".$ligne[0]."->".$ligne[1]."</p></div>";
Line 133... Line 133...
133
		
133
		
134
		//g&eacuten&eacuteration d'un fichier rdf pour chaque resultat de la requete
134
/*		//g&eacuten&eacuteration d'un fichier rdf pour chaque resultat de la requete
135
		$fic=$path_rdf;
135
		$fic=$path_rdf;
136
		$fic .=$ligne[0];
136
		$fic .=$ligne[0];
137
		$fic .=".rdf";
137
		$fic .=".rdf";
138
		if(!file_exists($fic))
138
		if(!file_exists($fic))
Line 177... Line 177...
177
			
177
			
Line 178... Line 178...
178
			$text_rdf .=">\n</rdf:Description>\n</rdf:RDF>\n";
178
			$text_rdf .=">\n</rdf:Description>\n</rdf:RDF>\n";
179
			
179
			
180
			$i=fwrite($fp,$text_rdf);
180
			$i=fwrite($fp,$text_rdf);
181
			fclose($fp);
181
			fclose($fp);
182
		}
182
		}*/
183
	}
183
	}
184
	if ($deb!=0)
184
	if ($deb!=0)
185
	{
185
	{
186
		if (($deb-$img_pg-1)>=0)
186
		if (($deb-$img_pg-1)>=0)
187
		{
187
		{
188
			$prec="<a href=photo.php?deb=".($deb-$img_pg-1).">Pr&eacutec&eacutedent</a>";
188
			$prec="<a href=eflore_photo.inc.php?deb=".($deb-$img_pg-1).">Pr&eacutec&eacutedent</a>";
189
			$res.="<div class=\"prec\">".$prec."</div>";
189
			$res.="<div class=\"prec\">".$prec."</div>";
190
		}
190
		}
191
		else
191
		else
192
		{
192
		{
193
			$prec="<a href=photo.php?deb=0>Pr&eacutec&eacutedent</a>";
193
			$prec="<a href=eflore_photo.inc.php?deb=0>Pr&eacutec&eacutedent</a>";
194
		}
194
		}
Line 195... Line 195...
195
		$res.="<div class=\"prec\">".$prec."</div>";
195
		$res.="<div class=\"prec\">".$prec."</div>";
196
	}
196
	}
197
	
197
	
198
	if ($deb+$img_pg<$nbre_ligne[0]) 
198
	if ($deb+$img_pg<$nbre_ligne[0]) 
199
	{
199
	{
Line 200... Line 200...
200
		$suiv="<a href=photo.php?deb=".($fin+1).">Suivant</a>";
200
		$suiv="<a href=eflore_photo.inc.php?deb=".($fin+1).">Suivant</a>";
Line 201... Line 201...
201
		$res.="<div class=\"suiv\">".$suiv."</div>";
201
		$res.="<div class=\"suiv\">".$suiv."</div>";
-
 
202
	}
202
	}
203
 
Line 203... Line 204...
203
 
204
}
204
}
205
 
205
 
206
DB::disconnect();
206
DB::disconnect();
207
}