Improved entropy for report file urls.
[fa-stable.git] / reporting / includes / excel_report.inc
index f139ba836465caa053f39ee787d1316b95341c25..c6f0d4436039b97519644a57e94f08c915baae3d 100644 (file)
@@ -81,10 +81,9 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook
                $rtl = ($_SESSION['language']->dir == 'rtl');
                $this->code = strtolower($_SESSION['language']->encoding);
                $this->filename = $filename.".xls";
-               $this->unique_name = uniqid('').".xls";
+               $this->unique_name = random_id().".xls";
                $this->path = company_path(). '/pdf_files';
                $this->Spreadsheet_Excel_Writer_Workbook($this->path."/".$this->unique_name);
-               //$this->setCountry(48);
                if ($this->code != "iso-8859-1")
                        $this->setVersion(8); // set biff version to 8 (0x0006 internal)
                $this->sheet =& $this->addWorksheet($this->worksheetNameGenerator($this->title));
@@ -198,10 +197,7 @@ class FrontReport extends Spreadsheet_Excel_Writer_Workbook
        {
                if (!isset($this->formatAmount[$dec]))
                {
-                       //global $thoseps,$decseps;
                        $dec = (int)$dec;
-                       //$tsep = $thoseps[user_tho_sep()];
-                       //$dsep = $decseps[user_dec_sep()];
                        $tsep = ',';
                        $dsep = '.';
                        $format = "###{$tsep}###{$tsep}###{$tsep}##0";