Subversion Repositories eFlore/Applications.eflore-consultation

Rev

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

Rev 678 Rev 679
Line 156... Line 156...
156
 //++ ------------------------------------------------export en pdf--------------------------------------++
156
 //++ ------------------------------------------------export en pdf--------------------------------------++
Line 157... Line 157...
157
	
157
	
158
 
158
 
159
	private function envoyerPdfAuNavigateur() {
159
	private function envoyerPdfAuNavigateur() {
160
		header('Content-type: application/pdf');
160
		header('Content-type: application/pdf');
161
		header('Content-Disposition: attachment; filename="'.$this->parametres['nom'].'.pdf"');
161
		header('Content-Disposition: attachment; filename="'.$this->nom_retenu.'.pdf"');
162
		readfile($this->fichier_pdf);
162
		readfile($this->fichier_pdf);
163
		unlink($this->fichier_html);
163
		unlink($this->fichier_html);
Line 164... Line 164...
164
		unlink($this->fichier_pdf);
164
		unlink($this->fichier_pdf);
165
	}
165
	}
166
	
166
	
167
	
167
	
168
		
168
		
169
	//version WKHTMLtoPDF en ligne de commande
169
	//version WKHTMLtoPDF en ligne de commande
170
	private function transformerHtmlEnPdf() {
170
	private function transformerHtmlEnPdf() {
171
		$time = $_SERVER['REQUEST_TIME'] ;
171
		$time = $_SERVER['REQUEST_TIME'] ;
172
		$this->fichier_html = $this->chemin_pdf.''.str_replace(' ','_',$this->parametres['nom']).'-'.$time.'.html';
172
		$this->fichier_html = $this->chemin_pdf.''.str_replace(' ','_',$this->nom_retenu).'-'.$time.'.html';
173
		$this->fichier_pdf = $this->chemin_pdf.''.str_replace(' ','_',$this->parametres['nom']).'-'.$time.'.pdf';
173
		$this->fichier_pdf = $this->chemin_pdf.''.str_replace(' ','_',$this->nom_retenu).'-'.$time.'.pdf';