diff --git a/dev/skeletons/skeleton_list.php b/dev/skeletons/skeleton_list.php
index 77485c6d6381f..4453f2d83022d 100644
--- a/dev/skeletons/skeleton_list.php
+++ b/dev/skeletons/skeleton_list.php
@@ -523,7 +523,7 @@ function init_myfunc()
$i++;
if ($i == 1)
{
- if ($num < $limit) print '
'.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/comm/propal/list.php b/htdocs/comm/propal/list.php
index d85448397de64..efb72afb7b79b 100644
--- a/htdocs/comm/propal/list.php
+++ b/htdocs/comm/propal/list.php
@@ -991,7 +991,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/commande/list.php b/htdocs/commande/list.php
index 80601ec972736..e62ae11d5cda5 100644
--- a/htdocs/commande/list.php
+++ b/htdocs/commande/list.php
@@ -1412,7 +1412,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/compta/bank/bankentries.php b/htdocs/compta/bank/bankentries.php
index 72e82dd0dd73e..4845012a3e0e5 100644
--- a/htdocs/compta/bank/bankentries.php
+++ b/htdocs/compta/bank/bankentries.php
@@ -1307,7 +1307,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totaldebfield'] == $i) print ''.price(-1 * $totalarray['totaldeb']).' | ';
diff --git a/htdocs/compta/bank/index.php b/htdocs/compta/bank/index.php
index 012dfe4217523..5f6e30016d459 100644
--- a/htdocs/compta/bank/index.php
+++ b/htdocs/compta/bank/index.php
@@ -607,7 +607,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalbalancefield'] == $i) print ''.price($totalarray['totalbalance'], 0, $langs, 0, 0, -1, $lastcurrencycode).' | ';
diff --git a/htdocs/compta/facture/list.php b/htdocs/compta/facture/list.php
index 693a6f39f9712..c5fd9b8048255 100644
--- a/htdocs/compta/facture/list.php
+++ b/htdocs/compta/facture/list.php
@@ -1117,7 +1117,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/compta/sociales/index.php b/htdocs/compta/sociales/index.php
index 66d6a65dd563b..e3f4a0b9b4d29 100644
--- a/htdocs/compta/sociales/index.php
+++ b/htdocs/compta/sociales/index.php
@@ -274,7 +274,7 @@
if (isset($totalarray['totalttcfield']))
{
print '';
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
print ' | ';
print ' | ';
diff --git a/htdocs/expensereport/list.php b/htdocs/expensereport/list.php
index 58541330c83a5..ca7a52ad29324 100644
--- a/htdocs/expensereport/list.php
+++ b/htdocs/expensereport/list.php
@@ -694,7 +694,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/fichinter/list.php b/htdocs/fichinter/list.php
index 9ef7d22ad1057..bafafb40dd163 100644
--- a/htdocs/fichinter/list.php
+++ b/htdocs/fichinter/list.php
@@ -518,7 +518,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totaldurationfield'] == $i) print ''.convertSecondToTime($totalarray['totalduration'], 'allhourmin').' | ';
diff --git a/htdocs/fourn/facture/list.php b/htdocs/fourn/facture/list.php
index 396d5ffd8a549..77064191d2474 100644
--- a/htdocs/fourn/facture/list.php
+++ b/htdocs/fourn/facture/list.php
@@ -970,7 +970,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/product/stock/productlot_list.php b/htdocs/product/stock/productlot_list.php
index 2910103e3807c..3d89aee001326 100644
--- a/htdocs/product/stock/productlot_list.php
+++ b/htdocs/product/stock/productlot_list.php
@@ -570,7 +570,7 @@ function init_myfunc()
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalhtfield'] == $i) print ''.price($totalarray['totalht']).' | ';
diff --git a/htdocs/projet/list.php b/htdocs/projet/list.php
index 51f260cac6f5a..408031a9ed274 100644
--- a/htdocs/projet/list.php
+++ b/htdocs/projet/list.php
@@ -854,7 +854,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totaloppfield'] == $i) print ''.price($totalarray['totalopp']).' | ';
diff --git a/htdocs/projet/tasks/list.php b/htdocs/projet/tasks/list.php
index 30a89109115d4..482c7b6f446cf 100644
--- a/htdocs/projet/tasks/list.php
+++ b/htdocs/projet/tasks/list.php
@@ -811,7 +811,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totalplannedworkloadfield'] == $i) print ''.convertSecondToTime($totalarray['totalplannedworkload'],$plannedworkloadoutputformat).' | ';
diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php
index 6cb52588a89d6..4c5d58dab7d52 100644
--- a/htdocs/projet/tasks/time.php
+++ b/htdocs/projet/tasks/time.php
@@ -971,7 +971,7 @@
$i++;
if ($i == 1)
{
- if ($num < $limit) print ''.$langs->trans("Total").' | ';
+ if ($num < $limit && empty($offset)) print ''.$langs->trans("Total").' | ';
else print ''.$langs->trans("Totalforthispage").' | ';
}
elseif ($totalarray['totaldurationfield'] == $i) print ''.convertSecondToTime($totalarray['totalduration'],'allhourmin').' | ';