diff --git a/htdocs/comm/action/agendaexport.php b/htdocs/comm/action/agendaexport.php index 850a7ef2c5e..ea2b5333880 100644 --- a/htdocs/comm/action/agendaexport.php +++ b/htdocs/comm/action/agendaexport.php @@ -109,10 +109,10 @@ if ($format == 'ical' || $format == 'vcal') $contenttype='text/calendar'; if (isset($_GET["contenttype"])) $contenttype=$_GET["contenttype"]; //$contenttype='text/plain'; - $outputencoding='UTF-8'; - if ($outputencoding) header('Content-Encoding: '.$outputencoding); - if ($contenttype) header('Content-Type: '.$contenttype); + //$contenttype='ISO-8859-1'; + + if ($contenttype) header('Content-Type: '.$contenttype.($outputencoding?'; charset='.$outputencoding:'')); if ($attachment) header('Content-Disposition: attachment; filename="'.$filename.'"'); // Ajout directives pour resoudre bug IE @@ -140,10 +140,10 @@ if ($format == 'rss') $contenttype='application/rss+xml'; if (isset($_GET["contenttype"])) $contenttype=$_GET["contenttype"]; //$contenttype='text/plain'; - $outputencoding='UTF-8'; - if ($outputencoding) header('Content-Encoding: '.$outputencoding); - if ($contenttype) header('Content-Type: '.$contenttype); + //$contenttype='ISO-8859-1'; + + if ($contenttype) header('Content-Type: '.$contenttype.($outputencoding?'; charset='.$outputencoding:'')); if ($attachment) header('Content-Disposition: attachment; filename="'.$filename.'"'); // Ajout directives pour resoudre bug IE diff --git a/htdocs/lib/xcal.lib.php b/htdocs/lib/xcal.lib.php index 994b8a33c3c..13ffdae40a8 100644 --- a/htdocs/lib/xcal.lib.php +++ b/htdocs/lib/xcal.lib.php @@ -55,7 +55,8 @@ function build_calfile($format='vcal',$title,$desc,$events_array,$outputfile,$fi fwrite($calfileh,"BEGIN:VCALENDAR\n"); fwrite($calfileh,"VERSION:2.0\n"); fwrite($calfileh,"METHOD:PUBLISH\n"); - fwrite($calfileh,"PRODID:-//DOLIBARR ".DOL_VERSION."//EN\n"); + //fwrite($calfileh,"PRODID:-//DOLIBARR ".DOL_VERSION."//EN\n"); + fwrite($calfileh,"PRODID:-//DOLIBARR ".DOL_VERSION."\n"); fwrite($calfileh,"CALSCALE:GREGORIAN\n"); fwrite($calfileh,"X-WR-CALNAME:".$encoding.format_cal($format,$title)."\n"); fwrite($calfileh,"X-WR-CALDESC:".$encoding.format_cal($format,$desc)."\n");