Subversion Repositories Sites.obs-saisons.fr

Rev

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

Rev 111 Rev 167
Line 46... Line 46...
46
    	$url_base_image = self::getUrlSquelette().'images'.DS;
46
    	$url_base_image = self::getUrlSquelette().'images'.DS;
Line 47... Line 47...
47
    	
47
    	
48
    	return $url_base_image;
48
    	return $url_base_image;
Line 49... Line 49...
49
    }
49
    }
-
 
50
    
-
 
51
    public static function getUrlImageEspece($nom_sci, $format = 'CXS') {
-
 
52
    	
-
 
53
    	$nom_sci_formate = strtolower(str_replace(' ', '_', $nom_sci));
50
    
54
    	
-
 
55
    	if(!file_exists(Config::get('dossier_images_especes').$format.'/'.$nom_sci_formate.'.jpg')) {
-
 
56
    		return Config::get('url_images_especes').$format.'/'.'vide.jpg';
-
 
57
       	}
51
    public static function getUrlImageEspece() {
58
       	
Line 52... Line 59...
52
    	return Config::get('url_images_especes').rand(1,5).'.jpeg';
59
    	return Config::get('url_images_especes').$format.'/'.$nom_sci_formate.'.jpg';
Line 53... Line 60...
53
    }
60
    }