Subversion Repositories eFlore/Projets.eflore-projets

Compare Revisions

No changes between revisions

Ignore whitespace Rev 365 → Rev 366

/trunk/services/modules/0.1/photoflora/ALIRE.txt
New file
0,0 → 1,8
; l'utilisation d'une redirection transparente des appels à l'api photoflora peut se faire
; en incluant dans le .htaccess du site, la ligne suivante :
RewriteRule ^service:eflore:([0-9]\.[0-9])/photoflora/images$ http://photoflora.free.fr/eflore-photoflora/services/index.php/$1/projets/photoflora/images
; Attention ! Il faut l'inclure avant la ligne de redirection des services web eflore
 
; Free ne supporte pas la redirection .htacess, il faut donc donc la désactiver dans le .htaccess de la racine des services
; Photoflora étant hébergé chez free, il faut changer ce paramètre dans le fichier de config général en ce qui suit
serveur.baseURL = "/eflore-photoflora/services/index.php/"
Property changes:
Added: svn:eol-style
+native
\ No newline at end of property
/trunk/services/modules/0.1/photoflora/Images.php
150,23 → 150,25
private function formaterRetourJson($photographies) {
$resultat = array();
foreach ($photographies as $photo) {
if(is_array($photographies)) {
foreach ($photographies as $photo) {
 
$image = array();
$url = $this->getUrlPhotoPourInitiales($photo['Initiales'], $photo['NumPhoto'], $this->format);
$urlmax = $this->getUrlPhotoPourInitiales($photo['Initiales'], $photo['NumPhoto'], 'max');
$id = str_replace(array('.jpg','.jpeg'),'',$photo['NumPhoto']);
// Post-traitement des valeurs
$image['station'] = $this->formaterChaineEncodeeBddPhotoflora($photo['lieu']);
$image['date'] = $this->donnerDate($this->formaterChaineEncodeeBddPhotoflora($photo['Date']));
$image['auteur'] = $this->formaterChaineEncodeeBddPhotoflora($photo['Prenom'].' '.$photo['Nom']);
$image['determination'] = $photo['Combinaison'].' ['.$photo['Prenom'].' '.$photo['Nom'].']';
$image['determination.nom_sci'] = $photo['Combinaison'];
$image['determination.nom_sci.code'] = "bdtfx.".$photo['NumNomen'];
$image['binaire.href'] = $url;
$image['binaire.hrefmax'] = $urlmax;
$resultat[$id] = $image;
$image = array();
$url = $this->getUrlPhotoPourInitiales($photo['Initiales'], $photo['NumPhoto'], $this->format);
$urlmax = $this->getUrlPhotoPourInitiales($photo['Initiales'], $photo['NumPhoto'], 'max');
$id = str_replace(array('.jpg','.jpeg'),'',$photo['NumPhoto']);
// Post-traitement des valeurs
$image['station'] = $this->formaterChaineEncodeeBddPhotoflora($photo['lieu']);
$image['date'] = $this->donnerDate($this->formaterChaineEncodeeBddPhotoflora($photo['Date']));
$image['auteur'] = $this->formaterChaineEncodeeBddPhotoflora($photo['Prenom'].' '.$photo['Nom']);
$image['determination'] = $photo['Combinaison'].' ['.$photo['Prenom'].' '.$photo['Nom'].']';
$image['determination.nom_sci'] = $photo['Combinaison'];
$image['determination.nom_sci.code'] = "bdtfx.".$photo['NumNomen'];
$image['binaire.href'] = $url;
$image['binaire.hrefmax'] = $urlmax;
$resultat[$id] = $image;
}
}
return $resultat;
/trunk/services/configurations/config_photoflora.ini
2,10 → 2,7
; mais sur photoflora.free.fr voir les notes en haut du web service
; ce fichier, par contre, est à laisser dans l'api eflore
 
; l'utilisation d'une redirection transparente des appels à l'api photoflora peut se faire
; en incluant dans le .htaccess du site, la ligne suivante :
; RewriteRule ^service:eflore:([0-9]\.[0-9])/photoflora/images$ http://photoflora.free.fr/eflore-photoflora/services/$1/projets/photoflora/images
; Attention ! Il faut l'inclure avant la ligne de redirection des services web eflore
; Pour plus d'infos, voir le fichier ALIRE.txt dans le répertoire de service de la classe photoflora
 
; Encodage : UTF-8