Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 1475 Rev 1478
Line 78... Line 78...
78
	
78
	
79
	private function executerObservation() {
79
	private function executerObservation() {
80
		$widget = null;
80
		$widget = null;
81
		extract($this->parametres);
81
		extract($this->parametres);
-
 
82
		$max_obs = (isset($max_obs) && preg_match('/^[0-9]+,[0-9]+$/', $max_obs)) ? $max_obs : '10';
82
		$max_obs = (isset($max_obs) && preg_match('/^[0-9]+,[0-9]+$/', $max_obs)) ? $max_obs : '10';
83
		$icone_rss = (isset($_GET['rss']) && $_GET['rss'] != 1) ? false : true;
-
 
84
		$this->flux_rss_url .= $this->traiterParametres();
83
		$this->flux_rss_url .= $this->traiterParametres();
85
		$titre = isset($titre) ? htmlentities(rawurldecode($titre)) : '';
84
		if (@file_get_contents($this->flux_rss_url, false) != false) {
86
		if (@file_get_contents($this->flux_rss_url, false) != false) {
85
			$xml = file_get_contents($this->flux_rss_url);
87
			$xml = file_get_contents($this->flux_rss_url);
86
			if ($xml) {
88
			if ($xml) {
87
				try {
89
				try {
Line 88... Line 90...
88
					$flux = new XmlFeedParser($xml);
90
					$flux = new XmlFeedParser($xml);
89
				
91
				
90
					$widget['donnees']['flux_rss_url'] = $this->flux_rss_url;
92
					$widget['donnees']['flux_rss_url'] = $this->flux_rss_url;
-
 
93
					$widget['donnees']['url_css'] = sprintf($this->config['chemins']['baseURLAbsoluDyn'], 'modules/observation/squelettes/css/');
-
 
94
					$widget['donnees']['colonne'] = 1;
91
					$widget['donnees']['url_css'] = sprintf($this->config['chemins']['baseURLAbsoluDyn'], 'modules/observation/squelettes/css/');
95
					$widget['donnees']['icone_rss'] = $icone_rss;
92
					$widget['donnees']['colonne'] = 1;
96
					$widget['donnees']['titre'] = $titre;
93
					$num = 0;
97
					$num = 0;
94
					foreach ($flux as $entree) {
98
					foreach ($flux as $entree) {
95
						if ($num == $max_obs) {
99
						if ($num == $max_obs) {