diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php
index 3f790907fc18fba0d4f1c1e032a84760e79c2479..40aa25798c4c9c5636ef1c56de3932c2189d7be1 100644
--- a/htdocs/main.inc.php
+++ b/htdocs/main.inc.php
@@ -1038,7 +1038,7 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
         $ext='version='.urlencode(DOL_VERSION);
         if (GETPOST('version')) $ext='version='.GETPOST('version','int');	// usefull to force no cache on css/js
         if (GETPOST('testmenuhider') || ! empty($conf->global->MAIN_TESTMENUHIDER)) $ext='testmenuhider='.GETPOST('testmenuhider','int');
-        
+
         if (! defined('DISABLE_JQUERY') && ! $disablejs && $conf->use_javascript_ajax)
         {
             print '<!-- Includes CSS for JQuery (Ajax library) -->'."\n";
@@ -1376,7 +1376,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
 
     $searchform='';
     $bookmarks='';
-    
+
     // Instantiate hooks of thirdparty module
     $hookmanager->initHooks(array('toprightmenu'));
 
@@ -1480,11 +1480,11 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
 	    if (empty($conf->global->MAIN_PRINT_DISABLELINK) && empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) && empty($conf->browser->phone))
 	    {
 	        $qs=$_SERVER["QUERY_STRING"];
-	        
+
 			foreach($_POST as $key=>$value) {
-				if($key!=='action')$qs.='&'.$key.'='.urlencode($value);
-			} 
-			
+				if($key!=='action' && !is_array($value))$qs.='&'.$key.'='.urlencode($value);
+			}
+
 			$qs.=(($qs && $morequerystring)?'&':'').$morequerystring;
 	        $text ='<a href="'.$_SERVER["PHP_SELF"].'?'.$qs.($qs?'&':'').'optioncss=print" target="_blank">';
 	        $text.= img_picto(":".$langs->trans("PrintContentArea"), 'printer_top.png', 'class="printer"');