Subversion Repositories eFlore/Applications.cel

Rev

Rev 1426 | Rev 1527 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1426 Rev 1468
1
<?php
1
<?php
2
/**
2
/**
3
* PHP Version 5
3
* PHP Version 5
4
*
4
*
5
* @category  PHP
5
* @category  PHP
6
* @package   jrest
6
* @package   jrest
7
* @author    David Delon <david.delon@clapas.net>
7
* @author    David Delon <david.delon@clapas.net>
8
* @copyright 2010 Tela-Botanica
8
* @copyright 2010 Tela-Botanica
9
* @license   http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL
9
* @license   http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL
10
* @version   SVN: <svn_id>
10
* @version   SVN: <svn_id>
11
* @link      /doc/jrest/
11
* @link      /doc/jrest/
12
*/
12
*/
13
 
13
 
14
/**
14
/**
15
* NameMap.php 
15
* NameMap.php 
16
* 
16
* 
17
* in utf8
17
* in utf8
18
* out utf8 
18
* out utf8 
19
* 
19
* 
20
* Cas d'utilisation :
20
* Cas d'utilisation :
21
* Service recherche d'image a partir d'un numero nomenclatural
21
* Service recherche d'image a partir d'un numero nomenclatural
22
* 
22
* 
23
* 1: Le service recoit un numero nomenclatural
23
* 1: Le service recoit un numero nomenclatural
24
* 2: Le service calcul le numero taxonomique associe
24
* 2: Le service calcul le numero taxonomique associe
25
* 3: Le service recherche une carte disponible
25
* 3: Le service recherche une carte disponible
26
* 		A: Pas de carte disponible, generation de l'image
26
* 		A: Pas de carte disponible, generation de l'image
27
*/
27
*/
28
 
-
 
29
// TODO: externaliser ceci dans le fichier de config
-
 
30
/** Constante stockant l'URL o. sont accessible les cartes. Le %s correspond au nom du fichier.*/
-
 
31
define('EF_URL_CARTO', 'http://www.tela-botanica.org/sites/eflore/generique/images/cartes/');
-
 
32
// france_BDNFF_4.02_nt8523.png
-
 
33
/** Constante stockant l'URL d'appel du module chorologie*/
-
 
34
define('EF_URL_CHORO', 'http://www.tela-botanica.org/eflore/BDNFF/4.02/nn/');
-
 
35
// 182/chorologie
-
 
36
 
28
 
37
class NameMap extends Cel  {
29
class NameMap extends Cel  {
38
 
30
 
39
	function getElement($uid){
31
	function getElement($uid){
40
 
-
 
-
 
32
		$url_service_chorologie = $this->config['eflore']['url_service_chorologie_carte'];
41
		$nt = null;
33
		$nt = null;
42
 
34
 
43
		if(isset($uid[0])) {
35
		if(isset($uid[0])) {
44
        $retour = array('');
36
        $retour = array('');
45
        	$file = 'http://localhost/service:eflore:0.1/chorodep/cartes/nn%3A'.$uid[0].'?retour.format=587&retour=image%2Fpng';
37
        	$file = $url_service_chorologie.'/nn%3A'.$uid[0].'?retour.format=587&retour=image%2Fpng';
46
			$retour = array($file);
38
			$retour = array($file);
47
        }    	    
39
        }    	    
48
 
40
 
49
		$this->envoyerJson($retour);			
41
		$this->envoyerJson($retour);			
50
		return true;	
42
		return true;	
51
	}
43
	}
52
}
44
}
53
/* +--Fin du code ---------------------------------------------------------------------------------------+
45
/* +--Fin du code ---------------------------------------------------------------------------------------+
54
* $Log$
46
* $Log$
55
* Revision 1.1  2008-01-30 08:57:28  ddelon
47
* Revision 1.1  2008-01-30 08:57:28  ddelon
56
* fin mise en place mygwt
48
* fin mise en place mygwt
57
*
49
*
58
* Revision 1.1  2007-06-06 13:31:16  ddelon
50
* Revision 1.1  2007-06-06 13:31:16  ddelon
59
* v0.09
51
* v0.09
60
*/
52
*/
61
?>
53
?>