diff --git a/htdocs/adherents/document.php b/htdocs/adherents/document.php
index 54e975c2f8c..8e12dec056e 100644
--- a/htdocs/adherents/document.php
+++ b/htdocs/adherents/document.php
@@ -144,7 +144,7 @@ if ($id > 0)
print '
| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
//Total taille
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
diff --git a/htdocs/comm/propal/document.php b/htdocs/comm/propal/document.php
index 8ef875f0a23..aab9cfcb30a 100644
--- a/htdocs/comm/propal/document.php
+++ b/htdocs/comm/propal/document.php
@@ -160,7 +160,7 @@ if ($object->id > 0)
// Files infos
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "\n";
diff --git a/htdocs/commande/document.php b/htdocs/commande/document.php
index 5a3f0c1973f..84cc9977e20 100644
--- a/htdocs/commande/document.php
+++ b/htdocs/commande/document.php
@@ -164,7 +164,7 @@ if ($id > 0 || ! empty($ref))
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "
\n";
diff --git a/htdocs/compta/bank/document.php b/htdocs/compta/bank/document.php
index 2fca317d1c4..a6e206c4b09 100644
--- a/htdocs/compta/bank/document.php
+++ b/htdocs/compta/bank/document.php
@@ -127,7 +127,7 @@ if ($id > 0 || !empty($ref)) {
print '';
print '| ' . $langs->trans("NbOfAttachedFiles") . ' | ' . count($filearray) . ' |
';
- print '| ' . $langs->trans("TotalSizeOfAttachedFiles") . ' | ' . $totalsize . ' ' . $langs->trans("bytes") . ' |
';
+ print '| ' . $langs->trans("TotalSizeOfAttachedFiles") . ' | ' .dol_print_size($totalsize,1,1).' |
';
print "
\n";
print '';
diff --git a/htdocs/compta/deplacement/document.php b/htdocs/compta/deplacement/document.php
index 1f3974ce041..76481c4c8c0 100644
--- a/htdocs/compta/deplacement/document.php
+++ b/htdocs/compta/deplacement/document.php
@@ -115,7 +115,7 @@ if ($object->id)
//print "| ".$langs->trans("Company")." | ".$object->client->getNomUrl(1)." |
";
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/compta/facture/document.php b/htdocs/compta/facture/document.php
index a9396e445c9..70dcfebaacb 100644
--- a/htdocs/compta/facture/document.php
+++ b/htdocs/compta/facture/document.php
@@ -171,7 +171,7 @@ if ($id > 0 || ! empty($ref))
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "
\n";
print "\n";
diff --git a/htdocs/compta/salaries/document.php b/htdocs/compta/salaries/document.php
index 03cef9c07e8..00bc6185ffd 100644
--- a/htdocs/compta/salaries/document.php
+++ b/htdocs/compta/salaries/document.php
@@ -118,7 +118,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/compta/sociales/document.php b/htdocs/compta/sociales/document.php
index 0bf1e7f6f13..0e2bcc5c986 100644
--- a/htdocs/compta/sociales/document.php
+++ b/htdocs/compta/sociales/document.php
@@ -150,7 +150,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/compta/tva/document.php b/htdocs/compta/tva/document.php
index 2fb7ba272c8..9ffc2202b8a 100644
--- a/htdocs/compta/tva/document.php
+++ b/htdocs/compta/tva/document.php
@@ -151,7 +151,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/contact/document.php b/htdocs/contact/document.php
index 281924cb589..2d729d8ebb4 100644
--- a/htdocs/contact/document.php
+++ b/htdocs/contact/document.php
@@ -153,7 +153,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/contrat/document.php b/htdocs/contrat/document.php
index 4bc2747a829..53125f3063b 100644
--- a/htdocs/contrat/document.php
+++ b/htdocs/contrat/document.php
@@ -181,7 +181,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/don/document.php b/htdocs/don/document.php
index 0ae81231bc1..020272d5bae 100644
--- a/htdocs/don/document.php
+++ b/htdocs/don/document.php
@@ -171,7 +171,7 @@ if ($object->id)
//print "| ".$langs->trans("Company")." | ".$object->client->getNomUrl(1)." |
";
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/expedition/document.php b/htdocs/expedition/document.php
index 87d0932c64b..48c551bb7d1 100644
--- a/htdocs/expedition/document.php
+++ b/htdocs/expedition/document.php
@@ -163,7 +163,7 @@ if ($id > 0 || ! empty($ref)){
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "
\n";
diff --git a/htdocs/expensereport/document.php b/htdocs/expensereport/document.php
index ed588f3f961..dc4f1c8a7af 100644
--- a/htdocs/expensereport/document.php
+++ b/htdocs/expensereport/document.php
@@ -118,7 +118,7 @@ if ($object->id)
$linkback = ''.$langs->trans("BackToList").'';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/fichinter/document.php b/htdocs/fichinter/document.php
index c869387b211..4c6d51e89fe 100644
--- a/htdocs/fichinter/document.php
+++ b/htdocs/fichinter/document.php
@@ -158,7 +158,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/fourn/commande/document.php b/htdocs/fourn/commande/document.php
index 11c3c59b313..59358279e31 100644
--- a/htdocs/fourn/commande/document.php
+++ b/htdocs/fourn/commande/document.php
@@ -168,7 +168,7 @@ if ($object->id > 0)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "
\n";
print "\n";
diff --git a/htdocs/fourn/facture/document.php b/htdocs/fourn/facture/document.php
index 5f8c5787773..1f0c9f86739 100644
--- a/htdocs/fourn/facture/document.php
+++ b/htdocs/fourn/facture/document.php
@@ -239,7 +239,7 @@ if ($object->id > 0)
// Nb of files
print '| '.$langs->trans('NbOfAttachedFiles').' | '.count($filearray).' |
';
- print '| '.$langs->trans('TotalSizeOfAttachedFiles').' | '.$totalsize.' '.$langs->trans('bytes').' |
';
+ print '| '.$langs->trans('TotalSizeOfAttachedFiles').' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/holiday/document.php b/htdocs/holiday/document.php
index 94d32b3bc49..6e5137e5b57 100644
--- a/htdocs/holiday/document.php
+++ b/htdocs/holiday/document.php
@@ -211,7 +211,7 @@ if ($object->id)
}
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print ''."\n";
diff --git a/htdocs/loan/document.php b/htdocs/loan/document.php
index 30f1efc69f7..54333029689 100644
--- a/htdocs/loan/document.php
+++ b/htdocs/loan/document.php
@@ -148,7 +148,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "
\n";
print "\n";
diff --git a/htdocs/product/document.php b/htdocs/product/document.php
index 93267538936..442eb3f53f3 100644
--- a/htdocs/product/document.php
+++ b/htdocs/product/document.php
@@ -227,7 +227,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
print '';
diff --git a/htdocs/projet/document.php b/htdocs/projet/document.php
index fbf9574bd75..4677e409f35 100644
--- a/htdocs/projet/document.php
+++ b/htdocs/projet/document.php
@@ -138,7 +138,7 @@ if ($object->id > 0)
// Files infos
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print "\n";
diff --git a/htdocs/resource/document.php b/htdocs/resource/document.php
index 64ac151fede..43b5a852b10 100644
--- a/htdocs/resource/document.php
+++ b/htdocs/resource/document.php
@@ -125,7 +125,7 @@ if ($object->id)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';
diff --git a/htdocs/societe/document.php b/htdocs/societe/document.php
index 2cab1da971f..e393fa64a2c 100644
--- a/htdocs/societe/document.php
+++ b/htdocs/societe/document.php
@@ -150,7 +150,7 @@ if ($object->id)
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
// Total size
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
diff --git a/htdocs/supplier_proposal/document.php b/htdocs/supplier_proposal/document.php
index 36c1df7329c..2be5dae222b 100644
--- a/htdocs/supplier_proposal/document.php
+++ b/htdocs/supplier_proposal/document.php
@@ -152,7 +152,7 @@ if ($object->id > 0)
print '';
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '
';
diff --git a/htdocs/user/document.php b/htdocs/user/document.php
index 5d89ef1b162..9e665bd563b 100644
--- a/htdocs/user/document.php
+++ b/htdocs/user/document.php
@@ -159,7 +159,7 @@ if ($object->id)
print '| '.$langs->trans("NbOfAttachedFiles").' | '.count($filearray).' |
';
//Total taille
- print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.$totalsize.' '.$langs->trans("bytes").' |
';
+ print '| '.$langs->trans("TotalSizeOfAttachedFiles").' | '.dol_print_size($totalsize,1,1).' |
';
print '';
print '';