Merge pull request #18008 from civicrm/5.28
[civicrm-core.git] / CRM / Utils / System / UnitTests.php
index f1d3ce640a1ee991cd17caa41ae22842b519bf5d..179906dbec0912abcaba25ff55983eaabbb3f774 100644 (file)
@@ -13,8 +13,6 @@
  *
  * @package CRM
  * @copyright CiviCRM LLC https://civicrm.org/licensing
- * $Id$
- *
  */
 
 /**
@@ -75,9 +73,9 @@ class CRM_Utils_System_UnitTests extends CRM_Utils_System_Base {
     $query = NULL,
     $absolute = FALSE,
     $fragment = NULL,
-    $htmlize = TRUE,
     $frontend = FALSE,
-    $forceBackend = FALSE
+    $forceBackend = FALSE,
+    $htmlize = TRUE
   ) {
     $config = CRM_Core_Config::singleton();
     static $script = 'index.php';
@@ -92,7 +90,7 @@ class CRM_Utils_System_UnitTests extends CRM_Utils_System_Base {
     }
     $base = $absolute ? $config->userFrameworkBaseURL : $config->useFrameworkRelativeBase;
 
-    $separator = $htmlize ? '&' : '&';
+    $separator = ($htmlize && $frontend) ? '&' : '&';
 
     if (!$config->cleanURL) {
       if (isset($path)) {