[ofbiz-framework] branch trunk updated: Improved: Add 'controlPath' attribute to 'ofbizUrl' freemarker macro

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated: Improved: Add 'controlPath' attribute to 'ofbizUrl' freemarker macro

James Yong-2
This is an automated email from the ASF dual-hosted git repository.

jamesyong pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 05ffbd2  Improved: Add 'controlPath' attribute to 'ofbizUrl' freemarker macro
05ffbd2 is described below

commit 05ffbd28177374004a5e63305ba338dc37729fa8
Author: James Yong <[hidden email]>
AuthorDate: Sun Jan 12 22:25:50 2020 +0800

    Improved: Add 'controlPath' attribute to 'ofbizUrl' freemarker macro
   
    (OFBIZ-11317)
   
    Adding the controlPath attribute to allow the controls by ofbizUrl to support uri to other OFBiz web application.
   
    Thanks: Jacques for the review
---
 .../template/ap/invoices/CommissionReport.ftl      |  6 ++--
 .../template/ap/invoices/CommissionRun.ftl         |  4 +--
 .../template/ap/invoices/PurchaseInvoices.ftl      |  4 +--
 .../template/ar/invoice/ListInvoices.ftl           |  4 +--
 .../template/ar/payment/BatchPayments.ftl          |  4 +--
 .../template/finaccounttrans/FinAccountTrans.ftl   |  6 ++--
 .../GlReconciledFinAccountTrans.ftl                |  2 +-
 .../template/lookup/ContentTreeLookupList.ftl      |  4 +--
 .../content/template/survey/GenericSurvey.ftl      |  2 +-
 .../manufacturing/template/bom/BomSimulation.ftl   |  4 +--
 applications/order/template/entry/BillSettings.ftl |  4 +--
 applications/order/template/entry/CheckInits.ftl   |  4 +--
 .../order/template/entry/OrderShortcuts.ftl        |  4 +--
 applications/order/template/entry/ShipSettings.ftl |  8 ++---
 .../order/template/entry/cart/ShowCartItems.ftl    |  4 +--
 .../order/template/entry/catalog/EditProduct.ftl   |  2 +-
 .../order/template/order/CreateAllocationPlan.ftl  |  8 ++---
 .../order/template/order/EditOrderItems.ftl        |  4 +--
 applications/order/template/order/FindOrders.ftl   |  2 +-
 applications/order/template/order/OrderInfo.ftl    |  6 ++--
 applications/order/template/order/OrderItems.ftl   | 22 ++++++-------
 applications/order/template/order/OrderList.ftl    |  2 +-
 .../order/template/order/OrderListByDate.ftl       |  6 ++--
 .../order/template/order/OrderPaymentInfo.ftl      | 38 +++++++++++-----------
 .../order/template/order/OrderShippingInfo.ftl     | 14 ++++----
 .../order/template/order/ViewAllocationPlan.ftl    | 12 +++----
 applications/order/template/quote/QuoteInfo.ftl    |  2 +-
 .../order/template/quote/ViewQuoteItemInfo.ftl     |  2 +-
 .../order/template/request/ViewRequestItemInfo.ftl |  2 +-
 applications/order/template/return/QuickReturn.ftl |  2 +-
 applications/order/template/return/ReturnItems.ftl | 16 ++++-----
 applications/order/template/task/OrderTaskList.ftl |  4 +--
 .../party/template/party/EditShoppingList.ftl      |  6 ++--
 .../party/template/party/profileblocks/Cart.ftl    |  2 +-
 .../template/party/profileblocks/FinAccounts.ftl   |  2 +-
 .../party/profileblocks/PaymentMethods.ftl         |  2 +-
 .../template/party/profileblocks/ProductStores.ftl |  2 +-
 .../party/profileblocks/SerializedInventory.ftl    |  4 +--
 .../product/category/ftl/UrlRegexpTransform.java   |  4 ++-
 .../template/category/EditCategoryParties.ftl      |  2 +-
 .../config/EditProductConfigItemContent.ftl        |  2 +-
 .../product/template/facility/PicklistOptions.ftl  |  6 ++--
 .../facility/ReviewOrdersNotPickedOrPacked.ftl     |  2 +-
 .../template/inventory/ReceiveInventory.ftl        |  8 ++---
 .../template/inventory/TransferInventoryItem.ftl   |  2 +-
 .../template/product/EditProductInventoryItems.ftl |  8 ++---
 .../template/product/ProductInventorySummary.ftl   |  2 +-
 .../product/template/product/ViewProductOrders.ftl |  2 +-
 .../product/template/returns/ReceiveReturn.ftl     |  8 ++---
 .../template/shipment/AddItemsFromInventory.ftl    |  6 ++--
 .../template/shipment/EditShipmentItems.ftl        |  6 ++--
 .../product/template/shipment/PackOrder.ftl        | 14 ++++----
 .../product/template/shipment/VerifyPick.ftl       |  8 ++---
 .../product/template/shipment/ViewShipmentInfo.ftl |  4 +--
 .../template/shipment/ViewShipmentItemInfo.ftl     |  6 ++--
 .../product/template/shipment/WeightPackage.ftl    |  4 +--
 .../template/store/EditProductStoreSurveys.ftl     |  2 +-
 .../template/store/EditProductStoreWebSites.ftl    |  4 +--
 .../template/calendar/CalendarEventContent.ftl     |  8 ++---
 .../ofbiz/webapp/control/RequestHandler.java       | 12 +++++--
 themes/tomahawk/template/AppBarClose.ftl           |  2 +-
 61 files changed, 179 insertions(+), 169 deletions(-)

diff --git a/applications/accounting/template/ap/invoices/CommissionReport.ftl b/applications/accounting/template/ap/invoices/CommissionReport.ftl
index 3b0565c..4967e16 100644
--- a/applications/accounting/template/ap/invoices/CommissionReport.ftl
+++ b/applications/accounting/template/ap/invoices/CommissionReport.ftl
@@ -35,13 +35,13 @@ under the License.
     <#assign alt_row = false>
     <#list commissionReportList as commissionReport>
       <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
-        <td><a href="/catalog/control/EditProduct?productId=${commissionReport.productId!}">${commissionReport.productName!}</a></td>
+        <td><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${commissionReport.productId!}</@ofbizUrl>">${commissionReport.productName!}</a></td>
         <td>${commissionReport.quantity!}</td>
         <td>
           ${commissionReport.numberOfOrders!} /
           <#if commissionReport.salesInvoiceIds?has_content>
             <#list commissionReport.salesInvoiceIds as salesInvoiceId>
-              [<a href="/ap/control/invoiceOverview?invoiceId=${salesInvoiceId!}">${salesInvoiceId!}</a>]
+              [<a href="<@ofbizUrl controlPath="/ap/control">invoiceOverview?invoiceId=${salesInvoiceId!}</@ofbizUrl>">${salesInvoiceId!}</a>]
             </#list>
           </#if>
         </td>
@@ -51,7 +51,7 @@ under the License.
           <#if commissionReport.salesAgentAndTermAmtMap?has_content>
             <#list commissionReport.salesAgentAndTermAmtMap.values() as partyIdAndTermAmountMap>
               <#assign partyName = (delegator.findOne("PartyNameView", {"partyId" : partyIdAndTermAmountMap.partyId}, true))!>
-              <h6>[${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}(<a href="/partymgr/control/viewprofile?partyId=${partyIdAndTermAmountMap.partyId!}">${partyIdAndTermAmountMap.partyId!}</a>)]
+              <h6>[${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}(<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${partyIdAndTermAmountMap.partyId!}</@ofbizUrl>">${partyIdAndTermAmountMap.partyId!}</a>)]
                 / <@ofbizCurrency amount = (partyIdAndTermAmountMap.termAmount)!/>
               </h6>
             </#list>
diff --git a/applications/accounting/template/ap/invoices/CommissionRun.ftl b/applications/accounting/template/ap/invoices/CommissionRun.ftl
index 2120346..93ece96 100644
--- a/applications/accounting/template/ap/invoices/CommissionRun.ftl
+++ b/applications/accounting/template/ap/invoices/CommissionRun.ftl
@@ -112,8 +112,8 @@ function enableSubmitButton() {
         <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
           <td><label><input type="checkbox" id="invoiceId_${invoice_index}" name="invoiceIds" value="${invoice.invoiceId}" onclick="javascript:enableSubmitButton();"/></label></td>
           <td><a class="buttontext" href="<@ofbizUrl>invoiceOverview?invoiceId=${invoice.invoiceId}</@ofbizUrl>">${invoice.get("invoiceId")}</a></td>
-          <td><a href="/partymgr/control/viewprofile?partyId=${invoice.partyIdFrom}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!}</a></td>
-          <td><a href="/partymgr/control/viewprofile?partyId=${invoice.invoiceRolePartyId}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.invoiceRolePartyId, false)!}</a></td>
+          <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.partyIdFrom}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!}</a></td>
+          <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.invoiceRolePartyId}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.invoiceRolePartyId, false)!}</a></td>
           <td>${statusItem.get("description")!}</td>
           <td>${invoice.get("referenceNumber")!}</td>
           <td>${invoice.get("description")!}</td>
diff --git a/applications/accounting/template/ap/invoices/PurchaseInvoices.ftl b/applications/accounting/template/ap/invoices/PurchaseInvoices.ftl
index 84f9c46..5da20bd 100644
--- a/applications/accounting/template/ap/invoices/PurchaseInvoices.ftl
+++ b/applications/accounting/template/ap/invoices/PurchaseInvoices.ftl
@@ -200,8 +200,8 @@ function runAction() {
             <td>${statusItem.description?default(invoice.statusId)}</td>
             <td>${invoice.get("referenceNumber")!}</td>
             <td>${(invoice.description)!}</td>
-            <td><a href="/partymgr/control/viewprofile?partyId=${invoice.partyIdFrom}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!} [${(invoice.partyIdFrom)!}] </a></td>
-            <td><a href="/partymgr/control/viewprofile?partyId=${invoice.partyId}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyId, false)!} [${(invoice.partyId)!}]</a></td>
+            <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.partyIdFrom}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!} [${(invoice.partyIdFrom)!}] </a></td>
+            <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.partyId}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyId, false)!} [${(invoice.partyId)!}]</a></td>
             <td><@ofbizCurrency amount=invoicePaymentInfo.amount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
             <td><@ofbizCurrency amount=invoicePaymentInfo.paidAmount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
             <td><@ofbizCurrency amount=invoicePaymentInfo.outstandingAmount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
diff --git a/applications/accounting/template/ar/invoice/ListInvoices.ftl b/applications/accounting/template/ar/invoice/ListInvoices.ftl
index 45ebe0b..9f3d7ae 100644
--- a/applications/accounting/template/ar/invoice/ListInvoices.ftl
+++ b/applications/accounting/template/ar/invoice/ListInvoices.ftl
@@ -176,8 +176,8 @@ under the License.
                 ${statusItem.description?default(invoice.statusId)}
               </td>
               <td>${(invoice.description)!}</td>
-              <td><a href="/partymgr/control/viewprofile?partyId=${invoice.partyIdFrom}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!} [${(invoice.partyIdFrom)!}] </a></td>
-              <td><a href="/partymgr/control/viewprofile?partyId=${invoice.partyId}">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyId, false)!} [${(invoice.partyId)!}]</a></td>
+              <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.partyIdFrom}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyIdFrom, false)!} [${(invoice.partyIdFrom)!}] </a></td>
+              <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${invoice.partyId}</@ofbizUrl>">${Static["org.apache.ofbiz.party.party.PartyHelper"].getPartyName(delegator, invoice.partyId, false)!} [${(invoice.partyId)!}]</a></td>
               <td><@ofbizCurrency amount=invoicePaymentInfo.amount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
               <td><@ofbizCurrency amount=invoicePaymentInfo.paidAmount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
               <td><@ofbizCurrency amount=invoicePaymentInfo.outstandingAmount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
diff --git a/applications/accounting/template/ar/payment/BatchPayments.ftl b/applications/accounting/template/ar/payment/BatchPayments.ftl
index 69f7902..17cb591 100644
--- a/applications/accounting/template/ar/payment/BatchPayments.ftl
+++ b/applications/accounting/template/ar/payment/BatchPayments.ftl
@@ -202,10 +202,10 @@ function setServiceName(selection) {
                         </td>
                         <td>${(payment.comments)!}</td>
                         <td>
-                          <a href="/partymgr/control/viewprofile?partyId=${payment.partyIdFrom}">${(payment.partyFromFirstName)!} ${(payment.partyFromLastName)!} ${(payment.partyFromGroupName)!}[${(payment.partyIdFrom)!}]</a>
+                          <a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${payment.partyIdFrom}</@ofbizUrl>">${(payment.partyFromFirstName)!} ${(payment.partyFromLastName)!} ${(payment.partyFromGroupName)!}[${(payment.partyIdFrom)!}]</a>
                         </td>
                         <td>
-                          <a href="/partymgr/control/viewprofile?partyId=${payment.partyIdTo}">${(payment.partyToFirstName)!} ${(payment.partyToLastName)!} ${(payment.partyToGroupName)!}[${(payment.partyIdTo)!}]</a>
+                          <a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${payment.partyIdTo}</@ofbizUrl>">${(payment.partyToFirstName)!} ${(payment.partyToLastName)!} ${(payment.partyToGroupName)!}[${(payment.partyIdTo)!}]</a>
                         </td>
                         <td>${payment.effectiveDate!}</td>
                         <td><@ofbizCurrency amount = payment.amount isoCode = payment.currencyUomId /></td>
diff --git a/applications/accounting/template/finaccounttrans/FinAccountTrans.ftl b/applications/accounting/template/finaccounttrans/FinAccountTrans.ftl
index de083b1..55009c9 100644
--- a/applications/accounting/template/finaccounttrans/FinAccountTrans.ftl
+++ b/applications/accounting/template/finaccounttrans/FinAccountTrans.ftl
@@ -212,8 +212,8 @@ function getFinAccountTransRunningTotalAndBalances() {
                         <td><#if paymentType?has_content>${paymentType.description!}</#if></td>
                         <td><#if paymentMethodType?has_content>${paymentMethodType.description!}</#if></td>
                         <td><@ofbizCurrency amount=payment.amount!/></td>
-                        <td><#if fromPartyName?has_content>${fromPartyName.groupName!}${fromPartyName.firstName!} ${fromPartyName.lastName!}<a href="/partymgr/control/viewprofile?partyId=${fromPartyName.partyId!}">[${fromPartyName.partyId!}]</a></#if></td>
-                        <td><#if toPartyName?has_content>${toPartyName.groupName!}${toPartyName.firstName!} ${toPartyName.lastName!}<a href="/partymgr/control/viewprofile?partyId=${toPartyName.partyId!}">[${toPartyName.partyId!}]</a></#if></td>
+                        <td><#if fromPartyName?has_content>${fromPartyName.groupName!}${fromPartyName.firstName!} ${fromPartyName.lastName!}<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${fromPartyName.partyId!}</@ofbizUrl>">[${fromPartyName.partyId!}]</a></#if></td>
+                        <td><#if toPartyName?has_content>${toPartyName.groupName!}${toPartyName.firstName!} ${toPartyName.lastName!}<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${toPartyName.partyId!}</@ofbizUrl>">[${toPartyName.partyId!}]</a></#if></td>
                       </tr>
                     </#list>
                   </table>
@@ -236,7 +236,7 @@ function getFinAccountTransRunningTotalAndBalances() {
               </#if>
             </td>
             <td>${finAccountTransType.description!}</td>
-            <td><#if partyName?has_content>${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}<a href="/partymgr/control/viewprofile?partyId=${partyName.partyId}">[${(partyName.partyId)!}]</a></#if></td>
+            <td><#if partyName?has_content>${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${partyName.partyId}</@ofbizUrl>">[${(partyName.partyId)!}]</a></#if></td>
             <td><#if glReconciliation?has_content>${glReconciliation.glReconciliationName!}<a href="ViewGlReconciliationWithTransaction?glReconciliationId=${glReconciliation.glReconciliationId!}&amp;finAccountId=${parameters.finAccountId!}">[${glReconciliation.glReconciliationId!}]</a></#if></td>
             <td>${finAccountTrans.transactionDate!}</td>
             <td>${finAccountTrans.entryDate!}</td>
diff --git a/applications/accounting/template/finaccounttrans/GlReconciledFinAccountTrans.ftl b/applications/accounting/template/finaccounttrans/GlReconciledFinAccountTrans.ftl
index 6846e1e..e6650e8 100644
--- a/applications/accounting/template/finaccounttrans/GlReconciledFinAccountTrans.ftl
+++ b/applications/accounting/template/finaccounttrans/GlReconciledFinAccountTrans.ftl
@@ -174,7 +174,7 @@ under the License.
                   <input id="finAccountTransId_${finAccountTrans_index}" name="_rowSubmit_o_${finAccountTrans_index}" type="hidden" value="Y"/>
                   ${finAccountTrans.finAccountTransId!}</td>
               <td>${finAccountTransType.description!}</td>
-              <td><#if partyName?has_content>${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}<a href="/partymgr/control/viewprofile?partyId=${partyName.partyId}">[${(partyName.partyId)!}]</a></#if></td>
+              <td><#if partyName?has_content>${(partyName.firstName)!} ${(partyName.lastName)!} ${(partyName.groupName)!}<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${partyName.partyId}</@ofbizUrl>">[${(partyName.partyId)!}]</a></#if></td>
               <td>${finAccountTrans.transactionDate!}</td>
               <td>${finAccountTrans.entryDate!}</td>
               <td><@ofbizCurrency amount=finAccountTrans.amount isoCode=defaultOrganizationPartyCurrencyUomId/></td>
diff --git a/applications/content/template/lookup/ContentTreeLookupList.ftl b/applications/content/template/lookup/ContentTreeLookupList.ftl
index 2e113de..8bc5f2b 100644
--- a/applications/content/template/lookup/ContentTreeLookupList.ftl
+++ b/applications/content/template/lookup/ContentTreeLookupList.ftl
@@ -76,8 +76,8 @@
       <#elseif tabButtonItem=="ListDocument">
           <#--Form ListDocument-->
           <tr <#if alt_row> class="alternate-row"</#if>>
-              <td><a class="plain" href="/content/control/editContent?contentId=${contentData.contentId!}">${contentData.contentName!}[${contentData.contentId!}]</a></td>
-              <td><a class="plain" href="/content/control/showContent?contentId=${contentData.contentId!}" target="_blank">${uiLabelMap.CommonView}</a></td>
+              <td><a class="plain" href="<@ofbizUrl controlPath="/content/control">editContent?contentId=${contentData.contentId!}</@ofbizUrl>">${contentData.contentName!}[${contentData.contentId!}]</a></td>
+              <td><a class="plain" href="<@ofbizUrl controlPath="/content/control">showContent?contentId=${contentData.contentId!}</@ofbizUrl>" target="_blank">${uiLabelMap.CommonView}</a></td>
               <td>${contentData.contentTypeId!}</td>
               <td>${contentData.mimeTypeId!}</td>
               <td>${contentData.statusId!}</td>
diff --git a/applications/content/template/survey/GenericSurvey.ftl b/applications/content/template/survey/GenericSurvey.ftl
index 299773e..734bcf6 100644
--- a/applications/content/template/survey/GenericSurvey.ftl
+++ b/applications/content/template/survey/GenericSurvey.ftl
@@ -69,7 +69,7 @@ under the License.
   <#elseif "CONTENT" == surveyQuestionAndAppl.surveyQuestionTypeId>
      <#if (answer.contentId)?has_content>
       <#assign content = answer.getRelatedOne("Content", false)>
-      <a href="/content/control/img?imgId=${content.dataResourceId}" class="buttontext">${answer.contentId}</a>&nbsp;-&nbsp;${content.contentName!}&nbsp;&nbsp;&nbsp;
+      <a href="<@ofbizUrl controlPath="/content/control">img?imgId=${content.dataResourceId}</@ofbizUrl>" class="buttontext">${answer.contentId}</a>&nbsp;-&nbsp;${content.contentName!}&nbsp;&nbsp;&nbsp;
     </#if>
     <input type="file" size="15" name="${questionFieldName}" class="inputBox"/>
   <#elseif "OPTION" == surveyQuestionAndAppl.surveyQuestionTypeId>
diff --git a/applications/manufacturing/template/bom/BomSimulation.ftl b/applications/manufacturing/template/bom/BomSimulation.ftl
index c1fd0c4..723e4c8 100644
--- a/applications/manufacturing/template/bom/BomSimulation.ftl
+++ b/applications/manufacturing/template/bom/BomSimulation.ftl
@@ -110,7 +110,7 @@ under the License.
           <#list productsData as productData>
             <#assign node = productData.node>
             <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
-              <td><a href="/catalog/control/EditProduct?productId=${node.product.productId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${node.product.productId}</a></td>
+              <td><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${node.product.productId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${node.product.productId}</a></td>
               <td>${node.product.internalName?default("&nbsp;")}</td>
               <td align="right">${node.quantity}</td>
               <td align="right">${productData.qoh!}</td>
@@ -118,7 +118,7 @@ under the License.
               <#if productData.unitCost?? && (productData.unitCost > 0)>
               <td align="right">${productData.unitCost!}</td>
               <#else>
-              <td align="right"><a href="/catalog/control/EditProductCosts?productId=${node.product.productId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">NA</a></td>
+              <td align="right"><a href="<@ofbizUrl controlPath="/catalog/control">EditProductCosts?productId=${node.product.productId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">NA</a></td>
               </#if>
               <td align="right">${productData.totalCost!}</td>
             </tr>
diff --git a/applications/order/template/entry/BillSettings.ftl b/applications/order/template/entry/BillSettings.ftl
index 2774ce2..6a74efb 100644
--- a/applications/order/template/entry/BillSettings.ftl
+++ b/applications/order/template/entry/BillSettings.ftl
@@ -106,7 +106,7 @@ function makeExpDate() {
                           ${uiLabelMap.OrderCardSecurityCode}&nbsp;<input type="text" size="5" maxlength="10" name="securityCode_${paymentMethod.paymentMethodId}" value=""/>
                         </span>
                       </td>
-                      <td align="right"><a href="/partymgr/control/editcreditcard?party_id=${orderParty.partyId}&amp;paymentMethodId=${paymentMethod.paymentMethodId}" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></td>
+                      <td align="right"><a href="<@ofbizUrl controlPath="/partymgr/control">editcreditcard?party_id=${orderParty.partyId}&amp;paymentMethodId=${paymentMethod.paymentMethodId}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></td>
                     </tr>
                   <#elseif "EFT_ACCOUNT" == paymentMethod.paymentMethodTypeId>
                     <#assign eftAccount = paymentMethod.getRelatedOne("EftAccount", false)>
@@ -118,7 +118,7 @@ function makeExpDate() {
                           <#if paymentMethod.description?has_content>(${paymentMethod.description})</#if>
                         </label>
                       </td>
-                      <td align="right"><a href="/partymgr/control/editeftaccount?party_id=${orderParty.partyId}&amp;paymentMethodId=${paymentMethod.paymentMethodId}" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></td>
+                      <td align="right"><a href="<@ofbizUrl controlPath="/partymgr/control">editeftaccount?party_id=${orderParty.partyId}&amp;paymentMethodId=${paymentMethod.paymentMethodId}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></td>
                     </tr>
                     <tr><td colspan="2"><hr /></td></tr>
                   </#if>
diff --git a/applications/order/template/entry/CheckInits.ftl b/applications/order/template/entry/CheckInits.ftl
index 0553297..fe4c0db 100644
--- a/applications/order/template/entry/CheckInits.ftl
+++ b/applications/order/template/entry/CheckInits.ftl
@@ -40,7 +40,7 @@ under the License.
         <div class="basic-nav">
           <ul>
             <li><a href="javascript:document.salesentryform.submit();">${uiLabelMap.CommonContinue}</a></li>
-            <li><a href="/partymgr/control/findparty?${StringUtil.wrapString(externalKeyParam)}">${uiLabelMap.PartyFindParty}</a></li>
+            <li><a href="<@ofbizUrl controlPath="/partymgr/control">findparty?${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>">${uiLabelMap.PartyFindParty}</a></li>
           </ul>
         </div>
       </ul>
@@ -126,7 +126,7 @@ under the License.
         <div class="basic-nav">
           <ul>
             <li><a href="javascript:document.poentryform.submit();">${uiLabelMap.CommonContinue}</a></li>
-            <li><a href="/partymgr/control/findparty?${StringUtil.wrapString(externalKeyParam)}">${uiLabelMap.PartyFindParty}</a></li>
+            <li><a href="<@ofbizUrl controlPath="/partymgr/control">findparty?${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>">${uiLabelMap.PartyFindParty}</a></li>
           </ul>
         </div>
       </ul>
diff --git a/applications/order/template/entry/OrderShortcuts.ftl b/applications/order/template/entry/OrderShortcuts.ftl
index a9e425a..cafc93a 100644
--- a/applications/order/template/entry/OrderShortcuts.ftl
+++ b/applications/order/template/entry/OrderShortcuts.ftl
@@ -36,13 +36,13 @@ under the License.
             <#if "SALES_ORDER" == shoppingCart.getOrderType()>
               <li><a href="<@ofbizUrl>createCustRequestFromCart?destroyCart=Y</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderCreateCustRequestFromCart}</a></li>
             </#if>
-            <li><a href="/partymgr/control/findparty?${externalKeyParam!}" class="buttontext">${uiLabelMap.PartyFindParty}</a></li>
+            <li><a href="<@ofbizUrl controlPath="/partymgr/control">findparty?${externalKeyParam!}</@ofbizUrl>" class="buttontext">${uiLabelMap.PartyFindParty}</a></li>
             <#if "SALES_ORDER" == shoppingCart.getOrderType()>
               <li><a href="<@ofbizUrl>setCustomer</@ofbizUrl>" class="buttontext">${uiLabelMap.PartyCreateNewCustomer}</a></li>
             </#if>
             <li><a href="<@ofbizUrl>checkinits</@ofbizUrl>" class="buttontext">${uiLabelMap.PartyChangeParty}</a></li>
             <#if security.hasEntityPermission("CATALOG", "_CREATE", session)>
-               <li><a href="/catalog/control/EditProduct?${externalKeyParam!}" target="catalog" class="buttontext">${uiLabelMap.ProductCreateNewProduct}</a></li>
+               <li><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?${externalKeyParam!}</@ofbizUrl>" target="catalog" class="buttontext">${uiLabelMap.ProductCreateNewProduct}</a></li>
             </#if>
             <li><a href="<@ofbizUrl>quickadd</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderQuickAdd}</a></li>
             <#if shoppingLists??>
diff --git a/applications/order/template/entry/ShipSettings.ftl b/applications/order/template/entry/ShipSettings.ftl
index ac22bb3..df93809 100644
--- a/applications/order/template/entry/ShipSettings.ftl
+++ b/applications/order/template/entry/ShipSettings.ftl
@@ -95,7 +95,7 @@ under the License.
                           </td>
                           <td nowrap="nowrap">&nbsp;&nbsp;&nbsp;&nbsp;</td>
                           <td>
-                            <div><a href="/facility/control/EditContactMech?facilityId=${facility.facilityId}&amp;contactMechId=${shippingAddress.contactMechId}" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
+                            <div><a href="<@ofbizUrl controlPath="/facility/control">EditContactMech?facilityId=${facility.facilityId}&amp;contactMechId=${shippingAddress.contactMechId}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
                           </td>
                         </tr>
                         <#if shippingContactMech_has_next>
@@ -109,7 +109,7 @@ under the License.
                       <td colspan="4">
                         <div>
                           ${uiLabelMap.CommonNoContactInformationOnFile}:
-                          <a href="/facility/control/EditContactMech?facilityId=${facility.facilityId}&amp;preContactMechTypeId=POSTAL_ADDRESS" target="_blank" class="buttontext">${uiLabelMap.CommonNew}</a>
+                          <a href="<@ofbizUrl controlPath="/facility/control">EditContactMech?facilityId=${facility.facilityId}&amp;preContactMechTypeId=POSTAL_ADDRESS</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonNew}</a>
                         </div>
                       </td>
                     </tr>
@@ -143,7 +143,7 @@ under the License.
               </td>
               <td nowrap="nowrap">&nbsp;&nbsp;&nbsp;&nbsp;</td>
               <td>
-                <div><a href="/partymgr/control/editcontactmech?partyId=${orderParty.partyId}&amp;contactMechId=${shippingContactMech.contactMechId}" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
+                <div><a href="<@ofbizUrl controlPath="/partymgr/control">editcontactmech?partyId=${orderParty.partyId}&amp;contactMechId=${shippingContactMech.contactMechId}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
               </td>
             </tr>
             <#if shippingContactMech_has_next>
@@ -243,7 +243,7 @@ under the License.
                         </label>
                       </td>
                       <td>
-                        <div><a href="/partymgr/control/editcontactmech?partyId=${orderParty.partyId}&amp;contactMechId=${shippingContactMech.contactMechId}" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
+                        <div><a href="<@ofbizUrl controlPath="/partymgr/control">editcontactmech?partyId=${orderParty.partyId}&amp;contactMechId=${shippingContactMech.contactMechId}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonUpdate}</a></div>
                       </td>
                     </tr>
                     <#if shippingContactMech_has_next>
diff --git a/applications/order/template/entry/cart/ShowCartItems.ftl b/applications/order/template/entry/cart/ShowCartItems.ftl
index 21148b0..0c9b1d5 100644
--- a/applications/order/template/entry/cart/ShowCartItems.ftl
+++ b/applications/order/template/entry/cart/ShowCartItems.ftl
@@ -109,7 +109,7 @@ under the License.
                     <#if cartLine.getAttribute("surveyResponses")?has_content>
                         <br />Surveys:
                        <#list cartLine.getAttribute("surveyResponses") as surveyResponseId>
-                        <a href="/content/control/ViewSurveyResponses?surveyResponseId=${surveyResponseId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" style="font-size: xx-small;">${surveyResponseId}</a>
+                        <a href="<@ofbizUrl controlPath="/content/control">ViewSurveyResponses?surveyResponseId=${surveyResponseId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" style="font-size: xx-small;">${surveyResponseId}</a>
                        </#list>
                     </#if>
                 </div>
@@ -147,7 +147,7 @@ under the License.
               <tr>
                 <td colspan="2">
                   <div>
-                    <a href="/catalog/control/EditProductInventoryItems?productId=${productId}" class="buttontext"><b>${uiLabelMap.ProductInventory}</b></a>:
+                    <a href="<@ofbizUrl controlPath="/catalog/control">EditProductInventoryItems?productId=${productId}</@ofbizUrl>" class="buttontext"><b>${uiLabelMap.ProductInventory}</b></a>:
                     ${uiLabelMap.ProductAtp} = ${availableToPromiseMap.get(productId)}, ${uiLabelMap.ProductQoh} = ${quantityOnHandMap.get(productId)}
                     <#if Static["org.apache.ofbiz.entity.util.EntityTypeUtil"].hasParentType(delegator, "ProductType", "productTypeId", product.productTypeId, "parentTypeId", "MARKETING_PKG")>
                     ${uiLabelMap.ProductMarketingPackageATP} = ${mktgPkgATPMap.get(productId)}, ${uiLabelMap.ProductMarketingPackageQOH} = ${mktgPkgQOHMap.get(productId)}
diff --git a/applications/order/template/entry/catalog/EditProduct.ftl b/applications/order/template/entry/catalog/EditProduct.ftl
index 88daf65..7f10eb5 100644
--- a/applications/order/template/entry/catalog/EditProduct.ftl
+++ b/applications/order/template/entry/catalog/EditProduct.ftl
@@ -19,6 +19,6 @@ under the License.
 
 <#if security.hasEntityPermission("CATALOG", "_CREATE", session)>
 <div>
-<a href="/catalog/control/EditProduct?productId=${productId}${externalKeyParam!}" target="catalog" class="buttontext">${uiLabelMap.ProductEditProduct}</a>
+<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${productId}${externalKeyParam!}</@ofbizUrl>" target="catalog" class="buttontext">${uiLabelMap.ProductEditProduct}</a>
 </div>
 </#if>
diff --git a/applications/order/template/order/CreateAllocationPlan.ftl b/applications/order/template/order/CreateAllocationPlan.ftl
index 4368167..7fd3626 100644
--- a/applications/order/template/order/CreateAllocationPlan.ftl
+++ b/applications/order/template/order/CreateAllocationPlan.ftl
@@ -91,9 +91,9 @@ under the License.
           <li class="h3">${uiLabelMap.OrderPlanItems}</li>
           <#if (allocationPlanInfo.itemList.size() &gt; 0)>
             <#if editMode=="Y">
-              <li><a href="/ordermgr/control/CreateAllocationPlan?productId=${requestParameters.productId!}&planName=${requestParameters.planName!}&editMode=N" class="buttontext">${uiLabelMap.OrderCancelEdit}</a></li>
+              <li><a href="<@ofbizUrl controlPath="/ordermgr/control">CreateAllocationPlan?productId=${requestParameters.productId!}&planName=${requestParameters.planName!}&editMode=N</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderCancelEdit}</a></li>
            <#else>
-              <li><a href="/ordermgr/control/CreateAllocationPlan?productId=${requestParameters.productId!}&planName=${requestParameters.planName!}&editMode=Y" class="buttontext">${uiLabelMap.CommonEdit}</a></li>
+              <li><a href="<@ofbizUrl controlPath="/ordermgr/control">CreateAllocationPlan?productId=${requestParameters.productId!}&planName=${requestParameters.planName!}&editMode=Y</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonEdit}</a></li>
             </#if>
           </#if>
         </ul>
@@ -122,8 +122,8 @@ under the License.
               <input type="hidden" name="ioisim_${item_index}" value="${item.orderItemSeqId}"/>
               <input type="hidden" name="ipsim_${item_index}" value="${item_index+1}"/>
               <td>${item.salesChannel!}</td>
-              <td><a href="/partymgr/control/viewprofile?partyId=${item.partyId!}" title="${item.partyId!}">${item.partyName!}</a></td>
-              <td><a href="/ordermgr/control/orderview?orderId=${item.orderId!}" title="${item.orderId!}">${item.orderId!}</a></td>
+              <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${item.partyId!}</@ofbizUrl>" title="${item.partyId!}">${item.partyName!}</a></td>
+              <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${item.orderId!}</@ofbizUrl>" title="${item.orderId!}">${item.orderId!}</a></td>
               <td>${item.orderItemSeqId!}</td>
               <td>${item.estimatedShipDate!}</td>
               <td align="right">${item.orderedQuantity!}</td>
diff --git a/applications/order/template/order/EditOrderItems.ftl b/applications/order/template/order/EditOrderItems.ftl
index 671b300..028e8f5 100644
--- a/applications/order/template/order/EditOrderItems.ftl
+++ b/applications/order/template/order/EditOrderItems.ftl
@@ -104,8 +104,8 @@ under the License.
                                   </div>
                                   <#if productId??>
                                   <div>
-                                      <a href="/catalog/control/EditProduct?productId=${productId}" class="buttontext" target="_blank">${uiLabelMap.ProductCatalog}</a>
-                                      <a href="/ecommerce/control/product?product_id=${productId}" class="buttontext" target="_blank">${uiLabelMap.OrderEcommerce}</a>
+                                      <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${productId}</@ofbizUrl>" class="buttontext" target="_blank">${uiLabelMap.ProductCatalog}</a>
+                                      <a href="<@ofbizUrl controlPath="/ecommerce/control">product?product_id=${productId}</@ofbizUrl>" class="buttontext" target="_blank">${uiLabelMap.OrderEcommerce}</a>
                                       <#if orderItemContentWrapper.get("IMAGE_URL", "url")?has_content>
                                       <a href="<@ofbizUrl>viewimage?orderId=${orderId}&amp;orderItemSeqId=${orderItem.orderItemSeqId}&amp;orderContentTypeId=IMAGE_URL</@ofbizUrl>" target="_orderImage" class="buttontext">${uiLabelMap.OrderViewImage}</a>
                                       </#if>
diff --git a/applications/order/template/order/FindOrders.ftl b/applications/order/template/order/FindOrders.ftl
index 22a1f5d..cb2c338 100644
--- a/applications/order/template/order/FindOrders.ftl
+++ b/applications/order/template/order/FindOrders.ftl
@@ -150,7 +150,7 @@ function toggleOrderIdList() {
         <li><a href="javascript:document.lookupandhidefields${requestParameters.hideFields}.submit()">${uiLabelMap.CommonShowLookupFields}</a></li>
       <#else>
         <#if orderList??><li><a href="javascript:document.lookupandhidefields${requestParameters.hideFields?default("Y")}.submit()">${uiLabelMap.CommonHideFields}</a></li></#if>
-        <li><a href="/partymgr/control/findparty?externalLoginKey=${requestAttributes.externalLoginKey!}">${uiLabelMap.PartyLookupParty}</a></li>
+        <li><a href="<@ofbizUrl controlPath="/partymgr/control">findparty?externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>">${uiLabelMap.PartyLookupParty}</a></li>
         <li><a href="javascript:lookupOrders(true);">${uiLabelMap.OrderLookupOrder}</a></li>
       </#if>
       </ul>
diff --git a/applications/order/template/order/OrderInfo.ftl b/applications/order/template/order/OrderInfo.ftl
index 8df1573..70ae94b 100644
--- a/applications/order/template/order/OrderInfo.ftl
+++ b/applications/order/template/order/OrderInfo.ftl
@@ -161,7 +161,7 @@ under the License.
               <tr>
                 <td class="label">&nbsp;${uiLabelMap.OrderProductStore}</td>
                 <td>
-                  ${productStore.storeName!}&nbsp;<a href="/catalog/control/EditProductStore?productStoreId=${productStore.productStoreId}${StringUtil.wrapString(externalKeyParam)}" target="catalogmgr" class="buttontext">(${productStore.productStoreId})</a>
+                  ${productStore.storeName!}&nbsp;<a href="<@ofbizUrl controlPath="/catalog/control">EditProductStore?productStoreId=${productStore.productStoreId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="catalogmgr" class="buttontext">(${productStore.productStoreId})</a>
                 </td>
               </tr>
               <tr><td colspan="3"><hr /></td></tr>
@@ -170,7 +170,7 @@ under the License.
               <td class="label">&nbsp;${uiLabelMap.OrderOriginFacility}</td>
               <td>
                   <#if orderHeader.originFacilityId?has_content>
-                    <a href="/facility/control/EditFacility?facilityId=${orderHeader.originFacilityId}${StringUtil.wrapString(externalKeyParam)}" target="facilitymgr" class="buttontext">${orderHeader.originFacilityId}</a>
+                    <a href="<@ofbizUrl controlPath="/facility/control">EditFacility?facilityId=${orderHeader.originFacilityId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="facilitymgr" class="buttontext">${orderHeader.originFacilityId}</a>
                   <#else>
                     ${uiLabelMap.CommonNA}
                   </#if>
@@ -181,7 +181,7 @@ under the License.
               <td class="label">&nbsp;${uiLabelMap.CommonCreatedBy}</td>
               <td>
                   <#if orderHeader.createdBy?has_content>
-                    <a href="/partymgr/control/viewprofile?userlogin_id=${orderHeader.createdBy}${StringUtil.wrapString(externalKeyParam)}" target="partymgr" class="buttontext">${orderHeader.createdBy}</a>
+                    <a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?userlogin_id=${orderHeader.createdBy}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="partymgr" class="buttontext">${orderHeader.createdBy}</a>
                   <#else>
                     ${uiLabelMap.CommonNotSet}
                   </#if>
diff --git a/applications/order/template/order/OrderItems.ftl b/applications/order/template/order/OrderItems.ftl
index fb406d4..ffbf1eb 100644
--- a/applications/order/template/order/OrderItems.ftl
+++ b/applications/order/template/order/OrderItems.ftl
@@ -84,11 +84,11 @@ under the License.
                                         <#assign downloadContents = EntityQuery.use(delegator).from("OrderItemAndProductContentInfo").where( "orderId", orderItem.orderId!, "orderItemSeqId", orderItem.orderItemSeqId!, "productContentTypeId", "DIGITAL_DOWNLOAD", "statusId", "ITEM_COMPLETED").queryList()!/>
                                         <#if downloadContents?has_content>
                                             <#list downloadContents as downloadContent>
-                                                <a href="/content/control/ViewSimpleContent?contentId=${downloadContent.contentId}" class="buttontext" target="_blank">${uiLabelMap.ContentDownload}</a>&nbsp;
+                                                <a href="<@ofbizUrl controlPath="/content/control">ViewSimpleContent?contentId=${downloadContent.contentId}</@ofbizUrl>" class="buttontext" target="_blank">${uiLabelMap.ContentDownload}</a>&nbsp;
                                             </#list>
                                         </#if>
-                                        <a href="/catalog/control/EditProduct?productId=${productId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${uiLabelMap.ProductCatalog}</a>
-                                        <a href="/ecommerce/control/product?product_id=${productId}" class="buttontext" target="_blank">${uiLabelMap.OrderEcommerce}</a>
+                                        <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${productId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${uiLabelMap.ProductCatalog}</a>
+                                        <a href="<@ofbizUrl controlPath="/ecommerce/control">product?product_id=${productId}</@ofbizUrl>" class="buttontext" target="_blank">${uiLabelMap.OrderEcommerce}</a>
                                         <#if orderItemContentWrapper.get("IMAGE_URL", "url")?has_content>
                                             <a href="<@ofbizUrl>viewimage?orderId=${orderId}&amp;orderItemSeqId=${orderItem.orderItemSeqId}&amp;orderContentTypeId=IMAGE_URL</@ofbizUrl>"
                                                target="_orderImage" class="buttontext">${uiLabelMap.OrderViewImage}</a>
@@ -349,7 +349,7 @@ under the License.
                                     <td colspan="6">
                                         <#if orderItem.orderItemTypeId != "RENTAL_ORDER_ITEM">
                                             <span class="label">${uiLabelMap.ManufacturingProductionRun}</span>
-                                            <a href="/manufacturing/control/ShowProductionRun?productionRunId=${workEffort.workEffortId}${StringUtil.wrapString(externalKeyParam)}"
+                                            <a href="<@ofbizUrl controlPath="/manufacturing/control">ShowProductionRun?productionRunId=${workEffort.workEffortId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                                 class="buttontext">${workEffort.workEffortId}</a>
                                             ${uiLabelMap.OrderCurrentStatus}
                                             ${(delegator.findOne("StatusItem", Static["org.apache.ofbiz.base.util.UtilMisc"].toMap("statusId", workEffort.getString("currentStatusId")), true).get("description",locale))!}
@@ -377,7 +377,7 @@ under the License.
                                     <td>&nbsp;</td>
                                     <td colspan="6">
                                         <span class="label">${uiLabelMap.OrderLinkedToOrderItem}</span>&nbsp;(${description!})
-                                        <a href="/ordermgr/control/orderview?orderId=${linkedOrderId}"
+                                        <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${linkedOrderId}</@ofbizUrl>"
                                            class="buttontext">${linkedOrderId}/${linkedOrderItemSeqId}</a>&nbsp;${linkedOrderItemValueStatus.description!}
                                     </td>
                                 </tr>
@@ -394,7 +394,7 @@ under the License.
                                     <td>&nbsp;</td>
                                     <td colspan="6">
                                         <span class="label">${uiLabelMap.OrderLinkedFromOrderItem}</span>&nbsp;(${description!})
-                                        <a href="/ordermgr/control/orderview?orderId=${linkedOrderId}"
+                                        <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${linkedOrderId}</@ofbizUrl>"
                                            class="buttontext">${linkedOrderId}/${linkedOrderItemSeqId}</a>&nbsp;${linkedOrderItemValueStatus.description!}
                                     </td>
                                 </tr>
@@ -439,7 +439,7 @@ under the License.
                                             (${orderItemAdjustment.comments?default("")})
                                         </#if>
                                         <#if orderItemAdjustment.productPromoId?has_content>
-                                            <a href="/catalog/control/EditProductPromo?productPromoId=${orderItemAdjustment.productPromoId}${StringUtil.wrapString(externalKeyParam)}"
+                                            <a href="<@ofbizUrl controlPath="/catalog/control">EditProductPromo?productPromoId=${orderItemAdjustment.productPromoId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                                 >${orderItemAdjustment.getRelatedOne("ProductPromo", false).getString("promoName")}</a>
                                         </#if>
                                         <#if "SALES_TAX" == orderItemAdjustment.orderAdjustmentTypeId>
@@ -504,7 +504,7 @@ under the License.
                                 <tr<#if "1" == itemClass> class="alternate-row"</#if>>
                                     <td align="right" colspan="2">
                                         <span class="label">${uiLabelMap.CommonSurveys}</span>&nbsp;
-                                        <a href="/content/control/ViewSurveyResponses?surveyResponseId=${survey.surveyResponseId}&amp;surveyId=${survey.surveyId}${StringUtil.wrapString(externalKeyParam)}"
+                                        <a href="<@ofbizUrl controlPath="/content/control">ViewSurveyResponses?surveyResponseId=${survey.surveyResponseId}&amp;surveyId=${survey.surveyId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                            class="buttontext">${survey.surveyId}</a>
                                     </td>
                                     <td colspan="5">&nbsp;</td>
@@ -568,7 +568,7 @@ under the License.
                                 <tr<#if "1" == itemClass> class="alternate-row"</#if>>
                                     <td align="right" colspan="2">
                                         <span class="label">${uiLabelMap.CommonInventory}</span>&nbsp;
-                                        <a href="/facility/control/EditInventoryItem?inventoryItemId=${orderItemShipGrpInvRes.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}"
+                                        <a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${orderItemShipGrpInvRes.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                            class="buttontext">${orderItemShipGrpInvRes.inventoryItemId}</a>
                                         <span class="label">${uiLabelMap.OrderShipGroup}</span>&nbsp;${orderItemShipGrpInvRes.shipGroupSeqId}
                                     </td>
@@ -636,7 +636,7 @@ under the License.
                                         <#if itemIssuance.inventoryItemId?has_content>
                                             <#assign inventoryItem = itemIssuance.getRelatedOne("InventoryItem", false)/>
                                             <span class="label">${uiLabelMap.CommonInventory}</span>
-                                            <a href="/facility/control/EditInventoryItem?inventoryItemId=${itemIssuance.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}"
+                                            <a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${itemIssuance.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                                class="buttontext">${itemIssuance.inventoryItemId}</a>
                                             <span class="label">${uiLabelMap.OrderShipGroup}</span>&nbsp;${itemIssuance.shipGroupSeqId!}
                                             <#if (inventoryItem.serialNumber?has_content)>
@@ -666,7 +666,7 @@ under the License.
                                         </#if>
                                         &nbsp;<#if shipmentReceipt.datetimeReceived?has_content>${Static["org.apache.ofbiz.base.util.UtilFormatOut"].formatDateTime(shipmentReceipt.datetimeReceived, "", locale, timeZone)!}</#if>&nbsp;
                                         <span class="label">${uiLabelMap.CommonInventory}</span>&nbsp;
-                                        <a href="/facility/control/EditInventoryItem?inventoryItemId=${shipmentReceipt.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}"
+                                        <a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${shipmentReceipt.inventoryItemId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
                                            class="buttontext">${shipmentReceipt.inventoryItemId}</a>
                                     </td>
                                     <td align="center">
diff --git a/applications/order/template/order/OrderList.ftl b/applications/order/template/order/OrderList.ftl
index e16dfb9..8ef7e5c 100644
--- a/applications/order/template/order/OrderList.ftl
+++ b/applications/order/template/order/OrderList.ftl
@@ -213,7 +213,7 @@ under the License.
                 <#assign trackingCodes = orderHeader.getRelated("TrackingCodeOrder", null, null, false)>
                 <#list trackingCodes as trackingCode>
                     <#if trackingCode?has_content>
-                        <a href="/marketing/control/FindTrackingCodeOrders?trackingCodeId=${trackingCode.trackingCodeId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}">${trackingCode.trackingCodeId}</a><br />
+                        <a href="<@ofbizUrl controlPath="/marketing/control">FindTrackingCodeOrders?trackingCodeId=${trackingCode.trackingCodeId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>">${trackingCode.trackingCodeId}</a><br />
                     </#if>
                 </#list>
               </td>
diff --git a/applications/order/template/order/OrderListByDate.ftl b/applications/order/template/order/OrderListByDate.ftl
index 18bda22..666ee52 100644
--- a/applications/order/template/order/OrderListByDate.ftl
+++ b/applications/order/template/order/OrderListByDate.ftl
@@ -23,7 +23,7 @@ under the License.
       <li class="h3">${uiLabelMap.OrderOrderReceivedOn} ${Static["org.apache.ofbiz.base.util.UtilDateTime"].toDateString(filterDate)}</li>
       <#assign listSize = state.getSize()>
       <#if (listSize > 10)>
-        <li><a href="/ordermgr/control/orderlist?viewIndex=${state.getViewIndex() + 1}&amp;viewSize=${state.getViewSize()}&amp;filterDate=${filterDate!}">${uiLabelMap.CommonMore}</a></li>
+        <li><a href="<@ofbizUrl controlPath="/ordermgr/control">orderlist?viewIndex=${state.getViewIndex() + 1}&amp;viewSize=${state.getViewSize()}&amp;filterDate=${filterDate!}</@ofbizUrl>">${uiLabelMap.CommonMore}</a></li>
       </#if>
       <#if orderHeaderList?has_content>
         <li>1-${orderHeaderList.size()} ${uiLabelMap.CommonOf} ${state.getSize()}</li>
@@ -54,7 +54,7 @@ under the License.
           <#assign productStore = orderHeader.getRelatedOne("ProductStore", true)! />
           <tr<#if alt_row> class="alternate-row"</#if>>
             <#assign alt_row = !alt_row>
-            <td><a href="/ordermgr/control/orderview?orderId=${orderHeader.orderId}" class="buttontext">${orderHeader.orderId}</a></td>
+            <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderHeader.orderId}</@ofbizUrl>" class="buttontext">${orderHeader.orderId}</a></td>
             <td>${billTo!}</td>
             <td><#if productStore?has_content>${productStore.storeName?default(productStore.productStoreId)}</#if></td>
             <td><@ofbizCurrency amount=orderHeader.grandTotal isoCode=orderHeader.currencyUom/></td>
@@ -62,7 +62,7 @@ under the License.
               <#assign trackingCodes = orderHeader.getRelated("TrackingCodeOrder", null, null, false)>
               <#list trackingCodes as trackingCode>
                 <#if trackingCode?has_content>
-                  <a href="/marketing/control/FindTrackingCodeOrders?trackingCodeId=${trackingCode.trackingCodeId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}">${trackingCode.trackingCodeId}</a><br />
+                  <a href="<@ofbizUrl controlPath="/marketing/control">FindTrackingCodeOrders?trackingCodeId=${trackingCode.trackingCodeId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>">${trackingCode.trackingCodeId}</a><br />
                 </#if>
               </#list>
             </td>
diff --git a/applications/order/template/order/OrderPaymentInfo.ftl b/applications/order/template/order/OrderPaymentInfo.ftl
index 9666810..388e458 100644
--- a/applications/order/template/order/OrderPaymentInfo.ftl
+++ b/applications/order/template/order/OrderPaymentInfo.ftl
@@ -55,13 +55,13 @@ under the License.
            <#assign partyName = delegator.findOne("PartyNameView", {"partyId" : payment.partyIdTo}, true)>
            <tr>
              <#if security.hasEntityPermission("PAY_INFO", "_VIEW", session) || security.hasEntityPermission("ACCOUNTING", "_VIEW", session)>
-               <td class="label"><a href="/accounting/control/paymentOverview?paymentId=${payment.paymentId}">${payment.paymentId}</a></td>
+               <td class="label"><a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${payment.paymentId}</@ofbizUrl>">${payment.paymentId}</a></td>
              <#else>
                <td class="label">${payment.paymentId}</td>
              </#if>
              <td>${partyName.groupName!}${partyName.lastName!} ${partyName.firstName!} ${partyName.middleName!}
              <#if security.hasPermission("PARTYMGR_VIEW", session) || security.hasPermission("PARTYMGR_ADMIN", session)>
-               [<a href="/partymgr/control/viewprofile?partyId=${partyId}">${partyId}</a>]
+               [<a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${partyId}</@ofbizUrl>">${partyId}</a>]
              <#else>
                [${partyId}]
              </#if>
@@ -78,8 +78,8 @@ under the License.
            <td class="label"><label>${uiLabelMap.OrderInvoices}</label></td>
            <td>
              <#list invoices as invoice>
-               <div>${uiLabelMap.CommonNbr}<a href="/accounting/control/invoiceOverview?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${invoice}</a>
-               (<a target="_BLANK" href="/accounting/control/invoice.pdf?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.CommonPdf}</a>)</div>
+               <div>${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">invoiceOverview?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${invoice}</a>
+               (<a target="_BLANK" href="<@ofbizUrl controlPath="/accounting/control">invoice.pdf?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPdf}</a>)</div>
              </#list>
            </td>
          </tr>
@@ -140,7 +140,7 @@ under the License.
                         <table class="basic-table" cellspacing='0'>
                             <tr>
                                 <td>
-                                    ${uiLabelMap.CommonNbr}<a href="/accounting/control/EditBillingAccount?billingAccountId=${billingAccount.billingAccountId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${billingAccount.billingAccountId}</a>  - ${billingAccount.description!}
+                                    ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">EditBillingAccount?billingAccountId=${billingAccount.billingAccountId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${billingAccount.billingAccountId}</a>  - ${billingAccount.description!}
                                 </td>
                                 <td>
                                     <#if orderPaymentPreference.statusId != "PAYMENT_SETTLED" && orderPaymentPreference.statusId != "PAYMENT_RECEIVED">
@@ -186,7 +186,7 @@ under the License.
                       <#if (finAccountType?has_content)>
                         ${finAccountType.description?default(finAccountType.finAccountTypeId)}&nbsp;
                       </#if>
-                      #${finAccount.finAccountCode?default(finAccount.finAccountId)} (<a href="/accounting/control/EditFinAccount?finAccountId=${finAccount.finAccountId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${finAccount.finAccountId}</a>)
+                      #${finAccount.finAccountCode?default(finAccount.finAccountId)} (<a href="<@ofbizUrl controlPath="/accounting/control">EditFinAccount?finAccountId=${finAccount.finAccountId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${finAccount.finAccountId}</a>)
                       <br />
                       ${finAccount.finAccountName!}
                       <br />
@@ -194,10 +194,10 @@ under the License.
                       <#-- Authorize and Capture transactions -->
                       <div>
                         <#if "PAYMENT_SETTLED" != orderPaymentPreference.statusId>
-                          <a href="/accounting/control/AuthorizeTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.AccountingAuthorize}</a>
+                          <a href="<@ofbizUrl controlPath="/accounting/control">AuthorizeTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.AccountingAuthorize}</a>
                         </#if>
                         <#if "PAYMENT_AUTHORIZED" == orderPaymentPreference.statusId>
-                          <a href="/accounting/control/CaptureTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.AccountingCapture}</a>
+                          <a href="<@ofbizUrl controlPath="/accounting/control">CaptureTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.AccountingCapture}</a>
                         </#if>
                       </div>
                     </div>
@@ -212,7 +212,7 @@ under the License.
                           (<span class="label">${uiLabelMap.OrderReference}</span>&nbsp;${gatewayResponse.referenceNum!}
                           <span class="label">${uiLabelMap.OrderAvs}</span>&nbsp;${gatewayResponse.gatewayAvsResult?default("N/A")}
                           <span class="label">${uiLabelMap.OrderScore}</span>&nbsp;${gatewayResponse.gatewayScoreResult?default("N/A")})
-                          <a href="/accounting/control/ViewGatewayResponse?paymentGatewayResponseId=${gatewayResponse.paymentGatewayResponseId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.CommonDetails}</a>
+                          <a href="<@ofbizUrl controlPath="/accounting/control">ViewGatewayResponse?paymentGatewayResponseId=${gatewayResponse.paymentGatewayResponseId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonDetails}</a>
                           <#if gatewayResponse_has_next><hr /></#if>
                         </#list>
                       </div>
@@ -242,7 +242,7 @@ under the License.
                       <td>
                         <div>
                             <#list paymentList as paymentMap>
-                                <a href="/accounting/control/paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
+                                <a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
                             </#list>
                         </div>
                       </td>
@@ -296,7 +296,7 @@ under the License.
                       <td>
                         <div>
                             <#list paymentList as paymentMap>
-                                <a href="/accounting/control/paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
+                                <a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
                             </#list>
                         </div>
                       </td>
@@ -343,10 +343,10 @@ under the License.
                       <#-- Authorize and Capture transactions -->
                       <div>
                         <#if "PAYMENT_SETTLED" != orderPaymentPreference.statusId>
-                          <a href="/accounting/control/AuthorizeTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.AccountingAuthorize}</a>
+                          <a href="<@ofbizUrl controlPath="/accounting/control">AuthorizeTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.AccountingAuthorize}</a>
                         </#if>
                         <#if "PAYMENT_AUTHORIZED" == orderPaymentPreference.statusId>
-                          <a href="/accounting/control/CaptureTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.AccountingCapture}</a>
+                          <a href="<@ofbizUrl controlPath="/accounting/control">CaptureTransaction?orderId=${orderId!}&amp;orderPaymentPreferenceId=${orderPaymentPreference.orderPaymentPreferenceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.AccountingCapture}</a>
                         </#if>
                       </div>
                     <#else>
@@ -364,7 +364,7 @@ under the License.
                         (<span class="label">${uiLabelMap.OrderReference}</span>&nbsp;${gatewayResponse.referenceNum!}
                         <span class="label">${uiLabelMap.OrderAvs}</span>&nbsp;${gatewayResponse.gatewayAvsResult?default("N/A")}
                         <span class="label">${uiLabelMap.OrderScore}</span>&nbsp;${gatewayResponse.gatewayScoreResult?default("N/A")})
-                        <a href="/accounting/control/ViewGatewayResponse?paymentGatewayResponseId=${gatewayResponse.paymentGatewayResponseId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.CommonDetails}</a>
+                        <a href="<@ofbizUrl controlPath="/accounting/control">ViewGatewayResponse?paymentGatewayResponseId=${gatewayResponse.paymentGatewayResponseId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonDetails}</a>
                         <#if gatewayResponse_has_next><hr /></#if>
                       </#list>
                     </div>
@@ -431,7 +431,7 @@ under the License.
                   <td>
                     <div>
                         <#list paymentList as paymentMap>
-                            <a href="/accounting/control/paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
+                            <a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
                         </#list>
                     </div>
                   </td>
@@ -488,7 +488,7 @@ under the License.
                   <td>
                     <div>
                         <#list paymentList as paymentMap>
-                            <a href="/accounting/control/paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
+                            <a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
                         </#list>
                     </div>
                   </td>
@@ -521,7 +521,7 @@ under the License.
               <td>
                 <div>
                     <#list paymentList as paymentMap>
-                        <a href="/accounting/control/paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
+                        <a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${paymentMap.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${paymentMap.paymentId}</a><#if paymentMap_has_next><br /></#if>
                     </#list>
                 </div>
               </td>
@@ -546,8 +546,8 @@ under the License.
             <td>&nbsp;<span class="label">${uiLabelMap.OrderInvoices}</span></td>
             <td>
               <#list invoices as invoice>
-                <div>${uiLabelMap.CommonNbr}<a href="/accounting/control/invoiceOverview?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${invoice}</a>
-                (<a target="_BLANK" href="/accounting/control/invoice.pdf?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.CommonPdf}</a>)</div>
+                <div>${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">invoiceOverview?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${invoice}</a>
+                (<a target="_BLANK" href="<@ofbizUrl controlPath="/accounting/control">invoice.pdf?invoiceId=${invoice}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonPdf}</a>)</div>
               </#list>
             </td>
             <td>&nbsp;</td>
diff --git a/applications/order/template/order/OrderShippingInfo.ftl b/applications/order/template/order/OrderShippingInfo.ftl
index 0138d2a..5ea9911 100644
--- a/applications/order/template/order/OrderShippingInfo.ftl
+++ b/applications/order/template/order/OrderShippingInfo.ftl
@@ -226,7 +226,7 @@ under the License.
               <#if (quantityOrdered > 0) >
           <tr id="tableevenrow">
               <td><div><a name="orderItem${index}">${orderItem.orderItemSeqId}</a></div></td>
-              <td><div>${product.internalName!} [<a href="/catalog/control/EditProduct?productId=${orderItem.productId!}" class="link">${orderItem.productId!}</a>]</div></td>
+              <td><div>${product.internalName!} [<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${orderItem.productId!}</@ofbizUrl>" class="link">${orderItem.productId!}</a>]</div></td>
               <td><div>${quantityOrdered}</div></td>
               <td><div>${quantityNotAvailable}</div></td>
               <td>
@@ -260,15 +260,15 @@ under the License.
                   <div class="tabletext"> [${OISG.shipGroupSeqId}] <#if OISG.shipByDate?has_content>, ${uiLabelMap.OrderShipBeforeDate} : ${OISG.shipByDate?date}</#if></div>
                       <#if "SALES_ORDER" == orderType>
                           <#list orderShipments as orderShipment>
-                  <div>${uiLabelMap.OrderPlannedInShipment} : </b><a target="facility" href="/facility/control/ViewShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${orderShipment.quantity!}</div>
+                  <div>${uiLabelMap.OrderPlannedInShipment} : </b><a target="facility" href="<@ofbizUrl controlPath="/facility/control">ViewShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}</@ofbizUrl>" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${orderShipment.quantity!}</div>
                           </#list>
                       <#elseif "PURCHASE_ORDER" == orderType>
                           <#list orderShipments as orderShipment>
                               <#if orderShipment.quantity?has_content & orderShipment.quantity!=0.0 >
-                  <div>${uiLabelMap.OrderPlannedInReceive} : </b><a target="facility" href="/facility/control/ViewReceiveShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${orderShipment.quantity!}</div>
+                  <div>${uiLabelMap.OrderPlannedInReceive} : </b><a target="facility" href="<@ofbizUrl controlPath="/facility/control">ViewReceiveShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}</@ofbizUrl>" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${orderShipment.quantity!}</div>
                               <#else>
                                   <#assign shipmentItem = orderShipment.getShipmentItem()>
-                  <div>${uiLabelMap.OrderPlannedRejected} : </b><a target="facility" href="/facility/control/ViewReceiveShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${shipmentItem.quantity!}</div>
+                  <div>${uiLabelMap.OrderPlannedRejected} : </b><a target="facility" href="<@ofbizUrl controlPath="/facility/control">ViewReceiveShipment?shipmentId=${orderShipment.shipmentId!}&externalLoginKey=${externalLoginKey}</@ofbizUrl>" class="buttontext" style="font-size: xx-small;">${orderShipment.shipmentId!}</a>:${orderShipment.shipmentItemSeqId!} - ${shipmentItem.quantity!}</div>
                               </#if>
                           </#list>
                       </#if>
@@ -754,8 +754,8 @@ under the License.
               <td>
                   <#list shipGroupShipments as shipment>
                       <div>
-                        ${uiLabelMap.CommonNbr}<a href="/facility/control/ViewShipment?shipmentId=${shipment.shipmentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${shipment.shipmentId}</a>&nbsp;&nbsp;
-                        <a target="_BLANK" href="/facility/control/PackingSlip.pdf?shipmentId=${shipment.shipmentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.ProductPackingSlip}</a>
+                        ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/facility/control">ViewShipment?shipmentId=${shipment.shipmentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${shipment.shipmentId}</a>&nbsp;&nbsp;
+                        <a target="_BLANK" href="<@ofbizUrl controlPath="/facility/control">PackingSlip.pdf?shipmentId=${shipment.shipmentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductPackingSlip}</a>
                         <#if "SALES_ORDER" == orderHeader.orderTypeId && "ORDER_COMPLETED" == orderHeader.statusId>
                           <#assign shipmentRouteSegments = EntityQuery.use(delegator).from("ShipmentRouteSegment").where("shipmentId", shipment.shipmentId!).queryList()!>
                           <#if shipmentRouteSegments?has_content>
@@ -787,7 +787,7 @@ under the License.
                <#if "SALES_ORDER" == orderHeader.orderTypeId>
                  <#if !shipGroup.supplierPartyId?has_content>
                    <#if "ORDER_APPROVED" == orderHeader.statusId>
-                 <a href="/facility/control/PackOrder?facilityId=${storeFacilityId!}&amp;orderId=${orderId}&amp;shipGroupSeqId=${shipGroup.shipGroupSeqId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.OrderPackShipmentForShipGroup}</a>
+                 <a href="<@ofbizUrl controlPath="/facility/control">PackOrder?facilityId=${storeFacilityId!}&amp;orderId=${orderId}&amp;shipGroupSeqId=${shipGroup.shipGroupSeqId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderPackShipmentForShipGroup}</a>
                    <br />
                    </#if>
                    <a href="javascript:document.createShipment_${shipGroup.shipGroupSeqId}.submit()" class="buttontext">${uiLabelMap.OrderNewShipmentForShipGroup}</a>
diff --git a/applications/order/template/order/ViewAllocationPlan.ftl b/applications/order/template/order/ViewAllocationPlan.ftl
index 33325f1..1d9b77c 100644
--- a/applications/order/template/order/ViewAllocationPlan.ftl
+++ b/applications/order/template/order/ViewAllocationPlan.ftl
@@ -121,9 +121,9 @@ under the License.
           <tbody>
             <tr>
               <td align="center"><label><b>${uiLabelMap.CommonName}</b></label></td>
-              <td align="left"><a href="/ordermgr/control/ViewAllocationPlan?planId=${allocationPlanInfo.planId!}" title="${allocationPlanInfo.planId!}"> ${allocationPlanInfo.planName!}</a></td>
+              <td align="left"><a href="<@ofbizUrl controlPath="/ordermgr/control">ViewAllocationPlan?planId=${allocationPlanInfo.planId!}</@ofbizUrl>" title="${allocationPlanInfo.planId!}"> ${allocationPlanInfo.planName!}</a></td>
               <td align="center"><label><b>${uiLabelMap.OrderProduct}</b></label></td>
-              <td align="left"><a href="/catalog/control/EditProduct?productId=${allocationPlanInfo.productId!}" title="${allocationPlanInfo.productId!}">${allocationPlanInfo.productName!}</a></td>
+              <td align="left"><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${allocationPlanInfo.productId!}</@ofbizUrl>" title="${allocationPlanInfo.productId!}">${allocationPlanInfo.productName!}</a></td>
               <td align="center"><label><b>${uiLabelMap.CommonCreatedBy}</b></label></td>
               <td align="left">${allocationPlanInfo.createdBy!}</td>
             </tr>
@@ -185,10 +185,10 @@ under the License.
         <ul>
           <li class="h3">${uiLabelMap.CommonItems}</li>
           <#if editMode>
-            <li><a href="/ordermgr/control/ViewAllocationPlan?planId=${allocationPlanInfo.planId!}" class="buttontext">${uiLabelMap.CommonCancel}</a></li>
+            <li><a href="<@ofbizUrl controlPath="/ordermgr/control">ViewAllocationPlan?planId=${allocationPlanInfo.planId!}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonCancel}</a></li>
             <li><a id="saveItemsButton" href="javascript: void(0);" class="buttontext">${uiLabelMap.CommonSave}</a></li>
           <#elseif allocationPlanInfo.statusId! != "ALLOC_PLAN_COMPLETED" && allocationPlanInfo.statusId! != "ALLOC_PLAN_CANCELLED" && security.hasPermission("ALLOCPLAN_UPDATE", session)>
-            <li><a href="/ordermgr/control/EditAllocationPlan?planId=${allocationPlanInfo.planId!}" class="buttontext">${uiLabelMap.CommonEdit}</a></li>
+            <li><a href="<@ofbizUrl controlPath="/ordermgr/control">EditAllocationPlan?planId=${allocationPlanInfo.planId!}</@ofbizUrl>" class="buttontext">${uiLabelMap.CommonEdit}</a></li>
           </#if>
         </ul>
         <br class="clear"/>
@@ -229,10 +229,10 @@ under the License.
                   </td>
                 </#if>
                 <td>${item.salesChannel!}</td>
-                <td><a href="/partymgr/control/viewprofile?partyId=${item.partyId!}" title="${item.partyId!}">${item.partyName!}</a></td>
+                <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${item.partyId!}</@ofbizUrl>" title="${item.partyId!}">${item.partyName!}</a></td>
                 <#assign statusItem = delegator.findOne("StatusItem", {"statusId" : item.statusId!}, false)!/>
                 <td>${statusItem.get("description")}</td>
-                <td><a href="/ordermgr/control/orderview?orderId=${item.orderId!}" title="${item.orderId!}">${item.orderId!}</a></td>
+                <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${item.orderId!}</@ofbizUrl>" title="${item.orderId!}">${item.orderId!}</a></td>
                 <td>${item.orderItemSeqId!}</td>
                 <td>${item.estimatedShipDate!}</td>
                 <td align="right">${item.orderedQuantity!}</td>
diff --git a/applications/order/template/quote/QuoteInfo.ftl b/applications/order/template/quote/QuoteInfo.ftl
index dc14015..d2b6278 100644
--- a/applications/order/template/quote/QuoteInfo.ftl
+++ b/applications/order/template/quote/QuoteInfo.ftl
@@ -73,7 +73,7 @@ under the License.
                         </#if>
                     </#if>
                     <#-- Link to the party in Party Manager -->
-                    <#if quote.partyId?has_content><a href="/partymgr/control/viewprofile?partyId=${quote.partyId}" class="buttontext" target="_blank">(${quote.partyId})</a></#if>
+                    <#if quote.partyId?has_content><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${quote.partyId}</@ofbizUrl>" class="buttontext" target="_blank">(${quote.partyId})</a></#if>
                 </td>
             </tr>
             <#-- quote name -->
diff --git a/applications/order/template/quote/ViewQuoteItemInfo.ftl b/applications/order/template/quote/ViewQuoteItemInfo.ftl
index 16bb9fe..844e214 100644
--- a/applications/order/template/quote/ViewQuoteItemInfo.ftl
+++ b/applications/order/template/quote/ViewQuoteItemInfo.ftl
@@ -83,7 +83,7 @@ under the License.
                               ${(product.internalName)!}&nbsp;
                             </#if>
                             <#if showQuoteManagementLinks??>
-                                <a href="/catalog/control/EditProduct?productId=${quoteItem.productId!}" class="buttontext">
+                                <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${quoteItem.productId!}</@ofbizUrl>" class="buttontext">
                                   <#if quoteItem.productId??>
                                     ${quoteItem.productId}
                                   <#else>
diff --git a/applications/order/template/request/ViewRequestItemInfo.ftl b/applications/order/template/request/ViewRequestItemInfo.ftl
index 61c138e..30cc78e 100644
--- a/applications/order/template/request/ViewRequestItemInfo.ftl
+++ b/applications/order/template/request/ViewRequestItemInfo.ftl
@@ -50,7 +50,7 @@ under the License.
                         <div>
                             ${(product.internalName)!}&nbsp;
                             <#if showRequestManagementLinks??>
-                                <a href="/catalog/control/EditProduct?productId=${requestItem.productId!}" class="buttontext">${requestItem.productId!}</a>
+                                <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${requestItem.productId!}</@ofbizUrl>" class="buttontext">${requestItem.productId!}</a>
                             <#else>
                                 <a href="<@ofbizUrl>product?product_id=${requestItem.productId!}</@ofbizUrl>" class="buttontext">${requestItem.productId!}</a>
                             </#if>
diff --git a/applications/order/template/return/QuickReturn.ftl b/applications/order/template/return/QuickReturn.ftl
index eed0429..580720a 100644
--- a/applications/order/template/return/QuickReturn.ftl
+++ b/applications/order/template/return/QuickReturn.ftl
@@ -61,7 +61,7 @@ under the License.
                 <input type='text' size='20' name='paymentMethodId' />
               </#if>
               <#if (party.partyId)?has_content>
-                <a href="/partymgr/control/editcreditcard?partyId=${party.partyId}${StringUtil.wrapString(externalKeyParam)}" target="partymgr" class="smallSubmit">${uiLabelMap.AccountingCreateCreditCard}</a>
+                <a href="<@ofbizUrl controlPath="/partymgr/control">editcreditcard?partyId=${party.partyId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="partymgr" class="smallSubmit">${uiLabelMap.AccountingCreateCreditCard}</a>
               </#if>
             </td></tr>
           </table>
diff --git a/applications/order/template/return/ReturnItems.ftl b/applications/order/template/return/ReturnItems.ftl
index 4c62a5f..f4d1ee8 100644
--- a/applications/order/template/return/ReturnItems.ftl
+++ b/applications/order/template/return/ReturnItems.ftl
@@ -71,16 +71,16 @@ under the License.
     <#if returnHeader?has_content>
       <#if returnHeader.destinationFacilityId?has_content && "RETURN_ACCEPTED" == returnHeader.statusId && returnHeader.returnHeaderTypeId?starts_with("CUSTOMER_")>
         <#list returnShipmentIds as returnShipmentId>
-          <a href="/facility/control/ViewShipment?shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.ProductShipmentId} ${returnShipmentId.shipmentId}</a>
-          <a href="/facility/control/ReceiveReturn?facilityId=${returnHeader.destinationFacilityId}&amp;returnId=${returnHeader.returnId!}&amp;shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.OrderReceiveReturn}</a>
+          <a href="<@ofbizUrl controlPath="/facility/control">ViewShipment?shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductShipmentId} ${returnShipmentId.shipmentId}</a>
+          <a href="<@ofbizUrl controlPath="/facility/control">ReceiveReturn?facilityId=${returnHeader.destinationFacilityId}&amp;returnId=${returnHeader.returnId!}&amp;shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderReceiveReturn}</a>
         </#list>
       <#elseif "SUP_RETURN_ACCEPTED" == returnHeader.statusId && "VENDOR_RETURN" == returnHeader.returnHeaderTypeId>
          <#if returnShipmentIds?has_content>
            <#list returnShipmentIds as returnShipmentId>
-             <a href="/facility/control/ViewShipment?shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.ProductShipmentId} ${returnShipmentId.shipmentId}</a>
+             <a href="<@ofbizUrl controlPath="/facility/control">ViewShipment?shipmentId=${returnShipmentId.shipmentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductShipmentId} ${returnShipmentId.shipmentId}</a>
            </#list>
          <#else>
-           <a href="/facility/control/EditShipment?primaryReturnId=${returnHeader.returnId}&amp;partyIdTo=${toPartyId}&amp;statusId=SHIPMENT_INPUT&amp;shipmentTypeId=PURCHASE_RETURN" class="buttontext">${uiLabelMap.OrderCreateReturnShipment}</a>
+           <a href="<@ofbizUrl controlPath="/facility/control">EditShipment?primaryReturnId=${returnHeader.returnId}&amp;partyIdTo=${toPartyId}&amp;statusId=SHIPMENT_INPUT&amp;shipmentTypeId=PURCHASE_RETURN</@ofbizUrl>" class="buttontext">${uiLabelMap.OrderCreateReturnShipment}</a>
          </#if>
       </#if>
     </#if>
@@ -162,7 +162,7 @@ under the License.
                 </td>
                 <td><div>
                     <#if item.get("productId")??>
-                        <a href="/catalog/control/EditProductInventoryItems?productId=${item.productId}" class="buttontext">${item.productId}</a>
+                        <a href="<@ofbizUrl controlPath="/catalog/control">EditProductInventoryItems?productId=${item.productId}</@ofbizUrl>" class="buttontext">${item.productId}</a>
                     <#else>
                         N/A
                     </#if></div></td>
@@ -182,7 +182,7 @@ under the License.
                     <#if item.receivedQuantity??>
                     <br />${uiLabelMap.OrderTotalQuantityReceive}: ${item.receivedQuantity}
                         <#list shipmentReceipts! as shipmentReceipt>
-                            <br />${uiLabelMap.OrderQty}: ${shipmentReceipt.quantityAccepted}, ${shipmentReceipt.datetimeReceived}, <a href="/facility/control/EditInventoryItem?inventoryItemId=${shipmentReceipt.inventoryItemId}" class="buttontext">${shipmentReceipt.inventoryItemId}</a>
+                            <br />${uiLabelMap.OrderQty}: ${shipmentReceipt.quantityAccepted}, ${shipmentReceipt.datetimeReceived}, <a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${shipmentReceipt.inventoryItemId}</@ofbizUrl>" class="buttontext">${shipmentReceipt.inventoryItemId}</a>
                         </#list>
                     </#if>
                     </div></td>
@@ -238,11 +238,11 @@ under the License.
                     <#assign itemResp = item.getRelatedOne("ReturnItemResponse", false)!>
                     <#if itemResp?has_content>
                       <#if itemResp.paymentId?has_content>
-                        <div>${uiLabelMap.AccountingPayment} ${uiLabelMap.CommonNbr}<a href="/accounting/control/paymentOverview?paymentId=${itemResp.paymentId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${itemResp.paymentId}</a></div>
+                        <div>${uiLabelMap.AccountingPayment} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">paymentOverview?paymentId=${itemResp.paymentId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${itemResp.paymentId}</a></div>
                       <#elseif itemResp.replacementOrderId?has_content>
                         <div>${uiLabelMap.OrderOrder} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl>orderview?orderId=${itemResp.replacementOrderId}</@ofbizUrl>" class="buttontext">${itemResp.replacementOrderId}</a></div>
                       <#elseif itemResp.billingAccountId?has_content>
-                        <div>${uiLabelMap.AccountingAccountId} ${uiLabelMap.CommonNbr}<a href="/accounting/control/EditBillingAccount?billingAccountId=${itemResp.billingAccountId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${itemResp.billingAccountId}</a></div>
+                        <div>${uiLabelMap.AccountingAccountId} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">EditBillingAccount?billingAccountId=${itemResp.billingAccountId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${itemResp.billingAccountId}</a></div>
                       </#if>
                     <#else>
                       <div>${uiLabelMap.CommonNone}</div>
diff --git a/applications/order/template/task/OrderTaskList.ftl b/applications/order/template/task/OrderTaskList.ftl
index c8456a2..e61420a 100644
--- a/applications/order/template/task/OrderTaskList.ftl
+++ b/applications/order/template/task/OrderTaskList.ftl
@@ -165,7 +165,7 @@ under the License.
                               </td>
                               <td>${task.priority?default("0")}</td>
                               <td>
-                                <a href="/workeffort/control/activity?workEffortId=${task.workEffortId}${StringUtil.wrapString(externalKeyParam)}" target="workeffort" class="buttontext">
+                                <a href="<@ofbizUrl controlPath="/workeffort/control">activity?workEffortId=${task.workEffortId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="workeffort" class="buttontext">
                                   ${Static["org.apache.ofbiz.order.task.TaskWorker"].getPrettyStatus(task)}
                                 </a>
                               </td>
@@ -259,7 +259,7 @@ under the License.
                                 <td>${Static["org.apache.ofbiz.order.task.TaskWorker"].getRoleDescription(task)}</td>
                                 <td>${task.priority?default("0")}</td>
                                 <td>
-                                  <a href="/workeffort/control/activity?workEffortId=${task.workEffortId}" target="workeffort" class="buttontext">
+                                  <a href="<@ofbizUrl controlPath="/workeffort/control">activity?workEffortId=${task.workEffortId}</@ofbizUrl>" target="workeffort" class="buttontext">
                                     ${Static["org.apache.ofbiz.order.task.TaskWorker"].getPrettyStatus(task)}
                                   </a>
                                 </td>
diff --git a/applications/party/template/party/EditShoppingList.ftl b/applications/party/template/party/EditShoppingList.ftl
index 89619a3..04efafe 100644
--- a/applications/party/template/party/EditShoppingList.ftl
+++ b/applications/party/template/party/EditShoppingList.ftl
@@ -65,8 +65,8 @@ under the License.
         <input type="submit" value="${uiLabelMap.PartyCreateNewQuote}"/>
       </form>
       </li>
-      <li><a href="/ordermgr/control/createCustRequestFromShoppingList?shoppingListId=${shoppingList.shoppingListId!}">${uiLabelMap.PartyCreateNewCustRequest}</a></li>
-      <li><a href="/ordermgr/control/loadCartFromShoppingList?shoppingListId=${shoppingList.shoppingListId!}">${uiLabelMap.OrderNewOrder}</a></li>
+      <li><a href="<@ofbizUrl controlPath="/ordermgr/control">createCustRequestFromShoppingList?shoppingListId=${shoppingList.shoppingListId!}</@ofbizUrl>">${uiLabelMap.PartyCreateNewCustRequest}</a></li>
+      <li><a href="<@ofbizUrl controlPath="/ordermgr/control">loadCartFromShoppingList?shoppingListId=${shoppingList.shoppingListId!}</@ofbizUrl>">${uiLabelMap.OrderNewOrder}</a></li>
     </ul>
     <br class="clear"/>
   </div>
@@ -199,7 +199,7 @@ under the License.
           <#assign productVariantAssocs = shoppingListItemData.productVariantAssocs!>
           <#assign isVirtual = product.isVirtual?? && "Y" == product.isVirtual>
           <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
-            <td><a href="/catalog/control/EditProduct?productId=${shoppingListItem.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}">${shoppingListItem.productId} -
+            <td><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${shoppingListItem.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>">${shoppingListItem.productId} -
               ${productContentWrapper.get("PRODUCT_NAME", "html")?default("No Name")}</a> : ${productContentWrapper.get("DESCRIPTION", "html")!}
             </td>
             <form method="post" action="<@ofbizUrl>removeFromShoppingList</@ofbizUrl>" name='removeform_${shoppingListItem.shoppingListItemSeqId}'>
diff --git a/applications/party/template/party/profileblocks/Cart.ftl b/applications/party/template/party/profileblocks/Cart.ftl
index affbf16..f9b102a 100644
--- a/applications/party/template/party/profileblocks/Cart.ftl
+++ b/applications/party/template/party/profileblocks/Cart.ftl
@@ -45,7 +45,7 @@ under the License.
             <#list savedCartItems as savedCartItem>
               <tr>
                 <td>${savedCartItem.shoppingListItemSeqId!}</td>
-                <td class="button-col"><a href="/catalog/control/EditProduct?productId=${savedCartItem.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}">${savedCartItem.productId!}</a></td>
+                <td class="button-col"><a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${savedCartItem.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>">${savedCartItem.productId!}</a></td>
                 <td>${savedCartItem.quantity!}</td>
                 <td>${savedCartItem.quantityPurchased!}</td>
               </tr>
diff --git a/applications/party/template/party/profileblocks/FinAccounts.ftl b/applications/party/template/party/profileblocks/FinAccounts.ftl
index 9d3c4de..eacedd8 100644
--- a/applications/party/template/party/profileblocks/FinAccounts.ftl
+++ b/applications/party/template/party/profileblocks/FinAccounts.ftl
@@ -19,7 +19,7 @@ under the License.
 
 <div style="border-bottom: 1px solid #ccc; margin-bottom: 20px">
     <p>
-        <b>${uiLabelMap.AccountingAccountNumber}:</b> <a href="/accounting/control/EditFinAccount?finAccountId=${ownedFinAccount.finAccountId}${StringUtil.wrapString(externalKeyParam)}"
+        <b>${uiLabelMap.AccountingAccountNumber}:</b> <a href="<@ofbizUrl controlPath="/accounting/control">EditFinAccount?finAccountId=${ownedFinAccount.finAccountId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>"
              class="smallSubmit">${ownedFinAccount.finAccountId}</a>
         <b>${uiLabelMap.AccountingAccountType}:</b> ${(ownedFinAccountType.description)?default('N/A')}
         <b>${uiLabelMap.FormFieldTitle_finAccountName}:</b> ${ownedFinAccount.finAccountName!}
diff --git a/applications/party/template/party/profileblocks/PaymentMethods.ftl b/applications/party/template/party/profileblocks/PaymentMethods.ftl
index baad093..a5ed3b8 100644
--- a/applications/party/template/party/profileblocks/PaymentMethods.ftl
+++ b/applications/party/template/party/profileblocks/PaymentMethods.ftl
@@ -82,7 +82,7 @@ under the License.
                 </td>
                 <td class="button-col">
                   <#if security.hasEntityPermission("MANUAL", "_PAYMENT", session)>
-                    <a href="/accounting/control/manualETx?paymentMethodId=${paymentMethod.paymentMethodId}${StringUtil.wrapString(externalKeyParam)}">${uiLabelMap.PartyManualTx}</a>
+                    <a href="<@ofbizUrl controlPath="/accounting/control">manualETx?paymentMethodId=${paymentMethod.paymentMethodId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>">${uiLabelMap.PartyManualTx}</a>
                   </#if>
                   <#if security.hasEntityPermission("PAY_INFO", "_UPDATE", session) || security.hasEntityPermission("ACCOUNTING", "_UPDATE", session)>
                     <a href="<@ofbizUrl>editcreditcard?partyId=${partyId}&amp;paymentMethodId=${paymentMethod.paymentMethodId}</@ofbizUrl>">${uiLabelMap.CommonUpdate}</a>
diff --git a/applications/party/template/party/profileblocks/ProductStores.ftl b/applications/party/template/party/profileblocks/ProductStores.ftl
index 61c2a02..610c95d 100644
--- a/applications/party/template/party/profileblocks/ProductStores.ftl
+++ b/applications/party/template/party/profileblocks/ProductStores.ftl
@@ -36,7 +36,7 @@ under the License.
           <#assign roleType = delegator.findOne("RoleType", {"roleTypeId" : productStoreRole.roleTypeId}, true) />
           <tr>
             <td class="button-col">
-              <a href="/catalog/control/FindProductStoreRoles?partyId=${productStoreRole.partyId}&amp;productStoreId=${productStore.productStoreId}">${productStore.storeName?default("${uiLabelMap.ProductNoDescription}")} (${productStore.productStoreId})</a>
+              <a href="<@ofbizUrl controlPath="/catalog/control">FindProductStoreRoles?partyId=${productStoreRole.partyId}&amp;productStoreId=${productStore.productStoreId}</@ofbizUrl>">${productStore.storeName?default("${uiLabelMap.ProductNoDescription}")} (${productStore.productStoreId})</a>
             </td>
             <td>${roleType.description!}</td>
           </tr>
diff --git a/applications/party/template/party/profileblocks/SerializedInventory.ftl b/applications/party/template/party/profileblocks/SerializedInventory.ftl
index d030bb7..691140b 100644
--- a/applications/party/template/party/profileblocks/SerializedInventory.ftl
+++ b/applications/party/template/party/profileblocks/SerializedInventory.ftl
@@ -40,7 +40,7 @@ under the License.
                 <#list inventoryItemList as inventoryItem>
                     <#assign product = inventoryItem.getRelatedOne('Product', false)!>
                     <tr>
-                        <td><a href="/facility/control/EditInventoryItem?inventoryItemId=${inventoryItem.inventoryItemId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}" class="linktext">${inventoryItem.inventoryItemId}</a></td>
+                        <td><a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${inventoryItem.inventoryItemId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>" class="linktext">${inventoryItem.inventoryItemId}</a></td>
                         <td>
                             <#if product?has_content>
                                 <#if product.isVariant?default('N') == 'Y'>
@@ -48,7 +48,7 @@ under the License.
                                 </#if>
                                 <#if product?has_content>
                                     <#assign productName = Static['org.apache.ofbiz.product.product.ProductContentWrapper'].getProductContentAsText(product, 'PRODUCT_NAME', request, "html")!>
-                                    <a href="/catalog/control/EditProduct?productId=${product.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}">${productName?default(product.productId)}</a>
+                                    <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>">${productName?default(product.productId)}</a>
                                 </#if>
                             </#if>
                         </td>
diff --git a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java
index 189df0b..48ac9b3 100644
--- a/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java
+++ b/applications/product/src/main/java/org/apache/ofbiz/product/category/ftl/UrlRegexpTransform.java
@@ -97,6 +97,7 @@ public class UrlRegexpTransform implements TemplateTransformModel {
         final boolean fullPath = checkArg(args, "fullPath", false);
         final boolean secure = checkArg(args, "secure", false);
         final boolean encode = checkArg(args, "encode", true);
+        final String controlPath = convertToString(args.get("controlPath"));
         final String webSiteId = convertToString(args.get("webSiteId"));
 
         return new Writer(out) {
@@ -133,7 +134,8 @@ public class UrlRegexpTransform implements TemplateTransformModel {
                         }
 
                         RequestHandler rh = RequestHandler.from(request);
-                        out.write(seoUrl(rh.makeLink(request, response, buf.toString(), fullPath, secure || request.isSecure() , encode), userLogin == null));
+                        String link = rh.makeLink(request, response, buf.toString(), fullPath, secure || request.isSecure() , encode, controlPath);
+                        out.write(seoUrl(link, userLogin == null));
                     } else if (!webSiteId.isEmpty()) {
                         Delegator delegator = FreeMarkerWorker.unwrap(env.getVariable("delegator"));
                         if (delegator == null) {
diff --git a/applications/product/template/category/EditCategoryParties.ftl b/applications/product/template/category/EditCategoryParties.ftl
index 5297cd6..09c7b5b 100644
--- a/applications/product/template/category/EditCategoryParties.ftl
+++ b/applications/product/template/category/EditCategoryParties.ftl
@@ -37,7 +37,7 @@ under the License.
             <#assign line = line + 1>
             <#assign curRoleType = productCategoryRole.getRelatedOne("RoleType", true)>
             <tr valign="middle"<#if "1" == rowClass> class="alternate-row"</#if>>
-            <td><a href="/partymgr/control/viewprofile?party_id=${(productCategoryRole.partyId)!}" target="_blank" class="buttontext">${(productCategoryRole.partyId)!}</a></td>
+            <td><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?party_id=${(productCategoryRole.partyId)!}</@ofbizUrl>" target="_blank" class="buttontext">${(productCategoryRole.partyId)!}</a></td>
             <td>${(curRoleType.get("description",locale))!}</td>
             <#assign hasntStarted = false>
             <#if (productCategoryRole.getTimestamp("fromDate"))?? && Static["org.apache.ofbiz.base.util.UtilDateTime"].nowTimestamp().before(productCategoryRole.getTimestamp("fromDate"))> <#assign hasntStarted = true></#if>
diff --git a/applications/product/template/config/EditProductConfigItemContent.ftl b/applications/product/template/config/EditProductConfigItemContent.ftl
index cd01bbc..c2f6a30 100644
--- a/applications/product/template/config/EditProductConfigItemContent.ftl
+++ b/applications/product/template/config/EditProductConfigItemContent.ftl
@@ -67,7 +67,7 @@ function insertImageName(size,nameValue) {
               <input name="fromDate" type="hidden" value="${productContent.fromDate}"/>
               <input type="submit" value="${uiLabelMap.CommonDelete}"/>
             </form>
-            <td><a href="/content/control/EditContent?contentId=${productContent.contentId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}" class="buttontext">${uiLabelMap.ProductEditContent} ${entry.content.contentId}</td>
+            <td><a href="<@ofbizUrl controlPath="/content/control">EditContent?contentId=${productContent.contentId}&amp;externalLoginKey=${requestAttributes.externalLoginKey!}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductEditContent} ${entry.content.contentId}</td>
          </tr>
          <#-- toggle the row color -->
          <#if "2" == rowClass>
diff --git a/applications/product/template/facility/PicklistOptions.ftl b/applications/product/template/facility/PicklistOptions.ftl
index 1d135f5..fdeb3c0 100644
--- a/applications/product/template/facility/PicklistOptions.ftl
+++ b/applications/product/template/facility/PicklistOptions.ftl
@@ -272,14 +272,14 @@ under the License.
             <#assign orderProduct = oiasga.getRelatedOne("OrderItem", false).getRelatedOne("Product", false)!>
             <#assign product = oiasga.getRelatedOne("InventoryItem", false).getRelatedOne("Product", false)!>
             <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
-              <td><a href="/ordermgr/control/orderview?orderId=${oiasga.orderId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${oiasga.orderId}</a></td>
+              <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${oiasga.orderId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${oiasga.orderId}</a></td>
               <td>${header.orderDate?string}</td>
               <td>${(channel.description)!}</td>
               <td>${oiasga.orderItemSeqId}</td>
               <td>
-                <a href="/catalog/control/EditProduct?productId=${orderProduct.productId!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${(orderProduct.internalName)!}</a>
+                <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${orderProduct.productId!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${(orderProduct.internalName)!}</a>
                 <#if orderProduct.productId != product.productId>
-                  &nbsp;[<a href="/catalog/control/EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${(product.internalName)!}</a>]
+                  &nbsp;[<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${(product.internalName)!}</a>]
                 </#if>
               </td>
               <td>${oiasga.shipGroupSeqId}</td>
diff --git a/applications/product/template/facility/ReviewOrdersNotPickedOrPacked.ftl b/applications/product/template/facility/ReviewOrdersNotPickedOrPacked.ftl
index 25f9541..8eef614 100644
--- a/applications/product/template/facility/ReviewOrdersNotPickedOrPacked.ftl
+++ b/applications/product/template/facility/ReviewOrdersNotPickedOrPacked.ftl
@@ -33,7 +33,7 @@ under the License.
             <#if orders?has_content>
                 <#list orders?sort_by("pickSheetPrintedDate") as order>
                     <tr>
-                        <td><a href="/ordermgr/control/orderview?orderId=${order.orderId!}" class="buttontext" target="_blank">${order.orderId!}</a></td>
+                        <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${order.orderId!}</@ofbizUrl>" class="buttontext" target="_blank">${order.orderId!}</a></td>
                         <td>${order.pickSheetPrintedDate!}</td>
                         <td><#if "Y" == order.isVerified>${uiLabelMap.CommonY}</#if></td>
                     </tr>
diff --git a/applications/product/template/inventory/ReceiveInventory.ftl b/applications/product/template/inventory/ReceiveInventory.ftl
index ed8db84..f575ef7 100644
--- a/applications/product/template/inventory/ReceiveInventory.ftl
+++ b/applications/product/template/inventory/ReceiveInventory.ftl
@@ -50,7 +50,7 @@ under the License.
                   <td><a href="<@ofbizUrl>ViewShipment?shipmentId=${item.shipmentId!}</@ofbizUrl>" class="buttontext">${item.shipmentId!} ${item.shipmentItemSeqId!}</a></td>
                   <td>${item.receiptId}</td>
                   <td>${item.getString("datetimeReceived").toString()}</td>
-                  <td><a href="/ordermgr/control/orderview?orderId=${item.orderId}" class="buttontext">${item.orderId}</a></td>
+                  <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${item.orderId}</@ofbizUrl>" class="buttontext">${item.orderId}</a></td>
                   <td>${item.orderItemSeqId}</td>
                   <td>${item.productId?default("Not Found")}</td>
                   <td>${item.lotId?default("")}</td>
@@ -110,7 +110,7 @@ under the License.
                 <td width="6%" align="right" nowrap="nowrap" class="label">${uiLabelMap.ProductProductName}</td>
                 <td width="6%">&nbsp;</td>
                 <td width="74%">
-                  <a href="/catalog/control/EditProduct?productId=${product.productId}${externalKeyParam!}" target="catalog" class="buttontext">${product.internalName!}</a>
+                  <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId}${externalKeyParam!}</@ofbizUrl>" target="catalog" class="buttontext">${product.internalName!}</a>
                 </td>
               </tr>
               <tr>
@@ -413,13 +413,13 @@ under the License.
                             <#assign product = orderItem.getRelatedOne("Product", true)/>
                             <input type="hidden" name="productId_o_${rowCount}" value="${product.productId}"/>
                             <td width="45%">
-                                ${orderItem.orderItemSeqId}:&nbsp;<a href="/catalog/control/EditProduct?productId=${product.productId}${externalKeyParam!}" target="catalog" class="buttontext">${product.productId}&nbsp;-&nbsp;${orderItem.itemDescription!}</a> : ${product.description!}
+                                ${orderItem.orderItemSeqId}:&nbsp;<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId}${externalKeyParam!}</@ofbizUrl>" target="catalog" class="buttontext">${product.productId}&nbsp;-&nbsp;${orderItem.itemDescription!}</a> : ${product.description!}
                             </td>
                           <#else>
                             <td width="45%">
                                 <b>${orderItemType.get("description",locale)}</b> : ${orderItem.itemDescription!}&nbsp;&nbsp;
                                 <input type="text" size="12" name="productId_o_${rowCount}"/>
-                                <a href="/catalog/control/EditProduct?${StringUtil.wrapString(externalKeyParam)}" target="catalog" class="buttontext">${uiLabelMap.ProductCreateProduct}</a>
+                                <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="catalog" class="buttontext">${uiLabelMap.ProductCreateProduct}</a>
                             </td>
                           </#if>
                           <td align="right">${uiLabelMap.ProductLocation}:</td>
diff --git a/applications/product/template/inventory/TransferInventoryItem.ftl b/applications/product/template/inventory/TransferInventoryItem.ftl
index d4ba9e5..e42f556 100644
--- a/applications/product/template/inventory/TransferInventoryItem.ftl
+++ b/applications/product/template/inventory/TransferInventoryItem.ftl
@@ -75,7 +75,7 @@ under the License.
                 <td width="6%">&nbsp;</td>
                 <td width="74%">
                     <#if inventoryItem?? && (inventoryItem.productId)??>
-                        <a href="/catalog/control/EditProduct?productId=${(inventoryItem.productId)!}" class="buttontext">${(inventoryItem.productId)!}</a>
+                        <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${(inventoryItem.productId)!}</@ofbizUrl>" class="buttontext">${(inventoryItem.productId)!}</a>
                     </#if>
                 </td>
             </tr>
diff --git a/applications/product/template/product/EditProductInventoryItems.ftl b/applications/product/template/product/EditProductInventoryItems.ftl
index fa50477..a357161 100644
--- a/applications/product/template/product/EditProductInventoryItems.ftl
+++ b/applications/product/template/product/EditProductInventoryItems.ftl
@@ -24,7 +24,7 @@ under the License.
     </div>
     <div class="screenlet-body">
         <#if productId?has_content>
-            <a href="/facility/control/EditInventoryItem?productId=${productId}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${uiLabelMap.ProductCreateNewInventoryItemProduct}</a>
+            <a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?productId=${productId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductCreateNewInventoryItemProduct}</a>
             <#if showEmpty>
                 <a href="<@ofbizUrl>EditProductInventoryItems?productId=${productId}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductHideEmptyItems}</a>
             <#else>
@@ -61,7 +61,7 @@ under the License.
                     <#assign inventoryItemDetailFirst = Static["org.apache.ofbiz.entity.util.EntityUtil"].getFirst(inventoryItem.getRelated("InventoryItemDetail", null, Static["org.apache.ofbiz.base.util.UtilMisc"].toList("effectiveDate"), false))!>
                     <#if curInventoryItemType??>
                         <tr valign="middle"<#if "1" == rowClass> class="alternate-row"</#if>>
-                            <td><a href="/facility/control/EditInventoryItem?inventoryItemId=${(inventoryItem.inventoryItemId)!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext">${(inventoryItem.inventoryItemId)!}</a></td>
+                            <td><a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${(inventoryItem.inventoryItemId)!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext">${(inventoryItem.inventoryItemId)!}</a></td>
                             <td>&nbsp;${(curInventoryItemType.get("description",locale))!}</td>
                             <td>
                                 <div>
@@ -80,13 +80,13 @@ under the License.
                                 <td style="color: red;">${uiLabelMap.ProductErrorFacility} (${inventoryItem.facilityId})
                                     ${uiLabelMap.ProductAndContainer} (${inventoryItem.containerId}) ${uiLabelMap.CommonSpecified}</td>
                             <#elseif inventoryItem.facilityId??>
-                                <td>${uiLabelMap.ProductFacilityLetter}:&nbsp;<a href="/facility/control/EditFacility?facilityId=${inventoryItem.facilityId}${StringUtil.wrapString(externalKeyParam)}" class="linktext">${inventoryItem.facilityId}</a></td>
+                                <td>${uiLabelMap.ProductFacilityLetter}:&nbsp;<a href="<@ofbizUrl controlPath="/facility/control">EditFacility?facilityId=${inventoryItem.facilityId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="linktext">${inventoryItem.facilityId}</a></td>
                             <#elseif (inventoryItem.containerId)??>
                                 <td>${uiLabelMap.ProductContainerLetter}:&nbsp;<a href="<@ofbizUrl>EditContainer?containerId=${inventoryItem.containerId }</@ofbizUrl>" class="linktext">${inventoryItem.containerId}</a></td>
                             <#else>
                                 <td>&nbsp;</td>
                             </#if>
-                            <td><a href="/facility/control/EditFacilityLocation?facilityId=${(inventoryItem.facilityId)!}&amp;locationSeqId=${(inventoryItem.locationSeqId)!}${StringUtil.wrapString(externalKeyParam)}" class="linktext"><#if facilityLocation??>${facilityLocation.areaId!}:${facilityLocation.aisleId!}:${facilityLocation.sectionId!}:${facilityLocation.levelId!}:${facilityLocation.positionId!}</#if><#if facilityLocationTypeEnum?has_content> (${facilityLocationTypeEnum.get("desc [...]
+                            <td><a href="<@ofbizUrl controlPath="/facility/control">EditFacilityLocation?facilityId=${(inventoryItem.facilityId)!}&amp;locationSeqId=${(inventoryItem.locationSeqId)!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="linktext"><#if facilityLocation??>${facilityLocation.areaId!}:${facilityLocation.aisleId!}:${facilityLocation.sectionId!}:${facilityLocation.levelId!}:${facilityLocation.positionId!}</#if><#if facilityLocationTypeEnum?has_content>  [...]
                             <td>&nbsp;${(inventoryItem.lotId)!}</td>
                             <td>&nbsp;${(inventoryItem.binNumber)!}</td>
                             <td align="right"><@ofbizCurrency amount=inventoryItem.unitCost isoCode=inventoryItem.currencyUomId/></td>
diff --git a/applications/product/template/product/ProductInventorySummary.ftl b/applications/product/template/product/ProductInventorySummary.ftl
index 71b395a..ee892b8 100644
--- a/applications/product/template/product/ProductInventorySummary.ftl
+++ b/applications/product/template/product/ProductInventorySummary.ftl
@@ -60,7 +60,7 @@ under the License.
                     <#assign outgoingQuantityTotal = manufacturingOutQuantitySummary.estimatedQuantityTotal!>
                     <tr valign="middle"<#if "1" == rowClass> class="alternate-row"</#if>>
                         <td>${(facility.facilityName)!} [${facilityId?default("[No Facility]")}]
-                        <a href="/facility/control/ReceiveInventory?facilityId=${facilityId}&amp;productId=${productId}&amp;externLoginKey=${externalLoginKey}" class="buttontext">${uiLabelMap.ProductInventoryReceive}</a></td>
+                        <a href="<@ofbizUrl controlPath="/facility/control">ReceiveInventory?facilityId=${facilityId}&amp;productId=${productId}&amp;externLoginKey=${externalLoginKey}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductInventoryReceive}</a></td>
                         <td><#if totalAvailableToPromise??>${totalAvailableToPromise}<#else>&nbsp;</#if></td>
                         <td><#if totalQuantityOnHand??>${totalQuantityOnHand}<#else>&nbsp;</#if></td>
                         <td><#if accountingQuantityTotal??>${accountingQuantityTotal}<#else>&nbsp;</#if></td>
diff --git a/applications/product/template/product/ViewProductOrders.ftl b/applications/product/template/product/ViewProductOrders.ftl
index 806075b..853b399 100644
--- a/applications/product/template/product/ViewProductOrders.ftl
+++ b/applications/product/template/product/ViewProductOrders.ftl
@@ -75,7 +75,7 @@ under the License.
           <#assign orderItems = EntityQuery.use(delegator).from("OrderItem").where("orderId", order.orderId!, "productId", productId!).queryList()!/>
           <#list orderItems as orderItem>
             <tr>
-              <td><a href="/ordermgr/control/orderview?orderId=${orderItem.orderId}" class='buttontext'>${orderItem.orderId}</a></td>
+              <td><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderItem.orderId}</@ofbizUrl>" class='buttontext'>${orderItem.orderId}</a></td>
               <#assign currentItemStatus = orderItem.getRelatedOne("StatusItem", false)/>
               <td>${currentItemStatus.get("description",locale)?default(currentItemStatus.statusId)}</td>
               <td>${orderItem.orderItemSeqId}</td>
diff --git a/applications/product/template/returns/ReceiveReturn.ftl b/applications/product/template/returns/ReceiveReturn.ftl
index ca95e19..201c820 100644
--- a/applications/product/template/returns/ReceiveReturn.ftl
+++ b/applications/product/template/returns/ReceiveReturn.ftl
@@ -23,7 +23,7 @@ under the License.
     <div class="screenlet-body">
         <#-- Receiving Results -->
         <#if receivedItems?has_content>
-          <h3>${uiLabelMap.ProductReceiptForReturn} ${uiLabelMap.CommonNbr}<a href="/ordermgr/control/returnMain?returnId=${returnHeader.returnId}${externalKeyParam!}" class="buttontext">${returnHeader.returnId}</a></h3>
+          <h3>${uiLabelMap.ProductReceiptForReturn} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/ordermgr/control">returnMain?returnId=${returnHeader.returnId}${externalKeyParam!}</@ofbizUrl>" class="buttontext">${returnHeader.returnId}</a></h3>
           <#if "RETURN_RECEIVED" == returnHeader.getString("statusId")>
             <h3>${uiLabelMap.ProductReturnCompletelyReceived}</h3>
           </#if>
@@ -71,7 +71,7 @@ under the License.
                 <tr>
                   <td>
                     <h3>
-                      ${uiLabelMap.ProductReceiveReturn} <a href="/ordermgr/control/returnMain?returnId=${returnHeader.returnId}${externalKeyParam!}" class="buttontext">#${returnHeader.returnId}</a>
+                      ${uiLabelMap.ProductReceiveReturn} <a href="<@ofbizUrl controlPath="/ordermgr/control">returnMain?returnId=${returnHeader.returnId}${externalKeyParam!}</@ofbizUrl>" class="buttontext">#${returnHeader.returnId}</a>
                       <#if parameters.shipmentId?has_content>${uiLabelMap.ProductShipmentId} <a href="<@ofbizUrl>ViewShipment?shipmentId=${parameters.shipmentId}</@ofbizUrl>" class="buttontext">${parameters.shipmentId}</a></#if>
                     </h3>
                   </td>
@@ -110,7 +110,7 @@ under the License.
                             <input type="hidden" name="productId_o_${rowCount}" value="${product.productId}" />
                             <td width="45%">
                               <div>
-                                ${returnItem.returnItemSeqId}:&nbsp;<a href="/catalog/control/EditProduct?productId=${product.productId}${externalKeyParam!}" target="catalog" class="buttontext">${product.productId}&nbsp;-&nbsp;${product.internalName!}</a> : ${product.description!}
+                                ${returnItem.returnItemSeqId}:&nbsp;<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId}${externalKeyParam!}</@ofbizUrl>" target="catalog" class="buttontext">${product.productId}&nbsp;-&nbsp;${product.internalName!}</a> : ${product.description!}
                                 <#if serializedInv?has_content><font color='red'>**${uiLabelMap.ProductSerializedInventoryFound}**</font></#if>
                               </div>
                             </td>
@@ -119,7 +119,7 @@ under the License.
                               <div>
                                 ${returnItem.returnItemSeqId}:&nbsp;<b>${orderItemType.get("description",locale)}</b> : ${orderItem.itemDescription!}&nbsp;&nbsp;
                                 <input type="text" size="12" name="productId_o_${rowCount}" />
-                                <a href="/catalog/control/EditProduct?${StringUtil.wrapString(externalKeyParam)}" target="catalog" class="buttontext">${uiLabelMap.ProductCreateProduct}</a>
+                                <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="catalog" class="buttontext">${uiLabelMap.ProductCreateProduct}</a>
                               </div>
                             </td>
                           <#else>
diff --git a/applications/product/template/shipment/AddItemsFromInventory.ftl b/applications/product/template/shipment/AddItemsFromInventory.ftl
index 6a6fe59..50fc471 100644
--- a/applications/product/template/shipment/AddItemsFromInventory.ftl
+++ b/applications/product/template/shipment/AddItemsFromInventory.ftl
@@ -37,15 +37,15 @@ under the License.
       </tr>
       <#list items as item>
         <tr>
-          <td><a href="/ordermgr/control/returnMain?returnId=${item.returnId}" class="buttontext">${item.returnId}</a> [${item.returnItemSeqId}]</td>
-          <td><a href="/catalog/control/EditProductInventoryItems?productId=${item.productId}" class="buttontext">${item.productId}</a> ${item.internalName!}</td>
+          <td><a href="<@ofbizUrl controlPath="/ordermgr/control">returnMain?returnId=${item.returnId}</@ofbizUrl>" class="buttontext">${item.returnId}</a> [${item.returnItemSeqId}]</td>
+          <td><a href="<@ofbizUrl controlPath="/catalog/control">EditProductInventoryItems?productId=${item.productId}</@ofbizUrl>" class="buttontext">${item.productId}</a> ${item.internalName!}</td>
           <td>${item.returnQuantity}</td>
           <td>${item.shipmentItemQty}</td>
           <td>${item.totalQtyIssued}</td>
           <td>
             <#if item.issuedItems?has_content>
               <#list item.issuedItems as issuedItem>
-                <div><a href="/facility/control/EditInventoryItem?inventoryItemId=${issuedItem.inventoryItemId}" class="buttontext">${issuedItem.inventoryItemId}</a> ${issuedItem.quantity}</div>
+                <div><a href="<@ofbizUrl controlPath="/facility/control">EditInventoryItem?inventoryItemId=${issuedItem.inventoryItemId}</@ofbizUrl>" class="buttontext">${issuedItem.inventoryItemId}</a> ${issuedItem.quantity}</div>
               </#list>
             </#if>
           </td>
diff --git a/applications/product/template/shipment/EditShipmentItems.ftl b/applications/product/template/shipment/EditShipmentItems.ftl
index 238d6cd..601d5dc 100644
--- a/applications/product/template/shipment/EditShipmentItems.ftl
+++ b/applications/product/template/shipment/EditShipmentItems.ftl
@@ -47,7 +47,7 @@ under the License.
             <#assign totalQuantityToPackage = shipmentItemData.totalQuantityToPackage>
             <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                 <td>${shipmentItem.shipmentItemSeqId}</td>
-                <td colspan="2">${(product.internalName)!} <a href="/catalog/control/EditProduct?productId=${shipmentItem.productId!}" class="buttontext">${shipmentItem.productId!}</a></td>
+                <td colspan="2">${(product.internalName)!} <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${shipmentItem.productId!}</@ofbizUrl>" class="buttontext">${shipmentItem.productId!}</a></td>
                 <td>${shipmentItem.quantity?default("&nbsp;")}</td>
                 <td colspan="2">${shipmentItem.shipmentContentDescription?default("&nbsp;")}</td>
                 <td>
@@ -61,7 +61,7 @@ under the License.
             <#list orderShipments as orderShipment>
                 <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                     <td>&nbsp;</td>
-                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="/ordermgr/control/orderview?orderId=${orderShipment.orderId!}" class="buttontext">${orderShipment.orderId!}</a> ${orderShipment.orderItemSeqId!}</td>
+                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderShipment.orderId!}</@ofbizUrl>" class="buttontext">${orderShipment.orderId!}</a> ${orderShipment.orderItemSeqId!}</td>
                     <td>&nbsp;</td>
                     <td>${orderShipment.quantity!}</td>
                     <td>&nbsp;</td>
@@ -72,7 +72,7 @@ under the License.
             <#list itemIssuances as itemIssuance>
                 <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                     <td>&nbsp;</td>
-                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="/ordermgr/control/orderview?orderId=${itemIssuance.orderId!}" class="buttontext">${itemIssuance.orderId!}</a> ${itemIssuance.orderItemSeqId!}</td>
+                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${itemIssuance.orderId!}</@ofbizUrl>" class="buttontext">${itemIssuance.orderId!}</a> ${itemIssuance.orderItemSeqId!}</td>
                     <td><span class="label">${uiLabelMap.ProductInventory}</span> <a href="<@ofbizUrl>EditInventoryItem?inventoryItemId=${itemIssuance.inventoryItemId!}</@ofbizUrl>" class="buttontext">${itemIssuance.inventoryItemId!}</a></td>
                     <td>${itemIssuance.quantity!}</td>
                     <td>${itemIssuance.issuedDateTime!}</td>
diff --git a/applications/product/template/shipment/PackOrder.ftl b/applications/product/template/shipment/PackOrder.ftl
index 786cf12..4e11b49 100644
--- a/applications/product/template/shipment/PackOrder.ftl
+++ b/applications/product/template/shipment/PackOrder.ftl
@@ -58,8 +58,8 @@ under the License.
                     <ul>
                     <#list invoiceIds as invoiceId>
                       <li>
-                        ${uiLabelMap.CommonNbr}<a href="/accounting/control/invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${invoiceId}</a>
-                        (<a href="/accounting/control/invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
+                        ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${invoiceId}</a>
+                        (<a href="<@ofbizUrl controlPath="/accounting/control">invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
                       </li>
                     </#list>
                     </ul>
@@ -142,7 +142,7 @@ under the License.
     <div class="screenlet">
         <div class="screenlet-title-bar">
             <ul>
-                <li class="h3">${uiLabelMap.ProductOrderId} ${uiLabelMap.CommonNbr}<a href="/ordermgr/control/orderview?orderId=${orderId}">${orderId}</a> / ${uiLabelMap.ProductOrderShipGroupId} #${shipGroupSeqId}</li>
+                <li class="h3">${uiLabelMap.ProductOrderId} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderId}</@ofbizUrl>">${orderId}</a> / ${uiLabelMap.ProductOrderShipGroupId} #${shipGroupSeqId}</li>
             </ul>
             <br class="clear"/>
         </div>
@@ -287,9 +287,9 @@ under the License.
                               </#if>
                           </td>
                           <td>
-                              <a href="/catalog/control/EditProduct?productId=${orderProduct.productId!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${(orderProduct.internalName)!}</a>
+                              <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${orderProduct.productId!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${(orderProduct.internalName)!}</a>
                               <#if orderProduct.productId != product.productId>
-                                  &nbsp;[<a href="/catalog/control/EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${(product.internalName)!}</a>]
+                                  &nbsp;[<a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${(product.internalName)!}</a>]
                               </#if>
                           </td>
                           <td align="right">${orderItemQuantity}</td>
@@ -456,7 +456,7 @@ under the License.
                       <td>${line.getOrderItemSeqId()}</td>
                       <td>${line.getProductId()?default("N/A")}</td>
                       <td>
-                          <a href="/catalog/control/EditProduct?productId=${line.getProductId()!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${product.internalName!?default("[N/A]")}</a>
+                          <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${line.getProductId()!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${product.internalName!?default("[N/A]")}</a>
                       </td>
                       <td>${line.getInventoryItemId()}</td>
                       <td align="right">${line.getQuantity()}</td>
@@ -500,7 +500,7 @@ under the License.
                       <td>${line.getOrderItemSeqId()}</td>
                       <td>${line.getProductId()?default("N/A")}</td>
                       <td>
-                          <a href="/catalog/control/EditProduct?productId=${line.getProductId()!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${product.internalName!?default("[N/A]")}</a>
+                          <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${line.getProductId()!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${product.internalName!?default("[N/A]")}</a>
                       </td>
                       <td>${line.getInventoryItemId()}</td>
                       <td align="right">${line.getQuantity()}</td>
diff --git a/applications/product/template/shipment/VerifyPick.ftl b/applications/product/template/shipment/VerifyPick.ftl
index eb563e0..ded6546 100644
--- a/applications/product/template/shipment/VerifyPick.ftl
+++ b/applications/product/template/shipment/VerifyPick.ftl
@@ -39,8 +39,8 @@ under the License.
           <ul>
             <#list invoiceIds as invoiceId>
               <li>
-                ${uiLabelMap.CommonNbr}<a href="/accounting/control/invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${invoiceId}</a>
-                (<a href="/accounting/control/invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
+                ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${invoiceId}</a>
+                (<a href="<@ofbizUrl controlPath="/accounting/control">invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
               </li>
             </#list>
           </ul>
@@ -106,7 +106,7 @@ under the License.
     <div class="screenlet">
       <div class="screenlet-title-bar">
         <ul>
-          <li class="h3">${uiLabelMap.ProductOrderId} ${uiLabelMap.CommonNbr}<a href="/ordermgr/control/orderview?orderId=${orderId}">${orderId}</a> / ${uiLabelMap.ProductOrderShipGroupId} #${shipGroupSeqId}</li>
+          <li class="h3">${uiLabelMap.ProductOrderId} ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderId}</@ofbizUrl>">${orderId}</a> / ${uiLabelMap.ProductOrderShipGroupId} #${shipGroupSeqId}</li>
         </ul>
         <br class="clear"/>
       </div>
@@ -234,7 +234,7 @@ under the License.
                   <td>${orderItemSeqId!}</td>
                   <td>${product.productId?default("N/A")}</td>
                   <td>
-                    <a href="/catalog/control/EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}" class="buttontext" target="_blank">${(product.internalName)!}</a>
+                    <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${product.productId!}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" class="buttontext" target="_blank">${(product.internalName)!}</a>
                   </td>
                   <td>
                     <select name="geo_${rowKey}">
diff --git a/applications/product/template/shipment/ViewShipmentInfo.ftl b/applications/product/template/shipment/ViewShipmentInfo.ftl
index 592e44a..917fc67 100644
--- a/applications/product/template/shipment/ViewShipmentInfo.ftl
+++ b/applications/product/template/shipment/ViewShipmentInfo.ftl
@@ -40,11 +40,11 @@ under the License.
           </tr>
           <tr>
             <td width="20%" align="right" class="label">${uiLabelMap.ProductPrimaryOrderId}</td>
-            <td width="80%"><#if shipment.primaryOrderId??><a href="/ordermgr/control/orderview?orderId=${shipment.primaryOrderId}" class="buttontext">${shipment.primaryOrderId}</a></#if></td>
+            <td width="80%"><#if shipment.primaryOrderId??><a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${shipment.primaryOrderId}</@ofbizUrl>" class="buttontext">${shipment.primaryOrderId}</a></#if></td>
           </tr>
           <tr>
             <td width="20%" align="right" class="label">${uiLabelMap.ProductPrimaryReturnId}</td>
-            <td width="80%"><#if shipment.primaryReturnId??><a href="/ordermgr/control/returnMain?returnId=${shipment.primaryReturnId}" class="buttontext">${shipment.primaryReturnId}</a></#if></td>
+            <td width="80%"><#if shipment.primaryReturnId??><a href="<@ofbizUrl controlPath="/ordermgr/control">returnMain?returnId=${shipment.primaryReturnId}</@ofbizUrl>" class="buttontext">${shipment.primaryReturnId}</a></#if></td>
           </tr>
           <tr>
             <td width="20%" align="right" class="label">${uiLabelMap.ProductPrimaryShipGroupSeqId}</td>
diff --git a/applications/product/template/shipment/ViewShipmentItemInfo.ftl b/applications/product/template/shipment/ViewShipmentItemInfo.ftl
index b936b66..bef1770 100644
--- a/applications/product/template/shipment/ViewShipmentItemInfo.ftl
+++ b/applications/product/template/shipment/ViewShipmentItemInfo.ftl
@@ -37,14 +37,14 @@ under the License.
             <#assign product = shipmentItemData.product!>
             <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                 <td>${shipmentItem.shipmentItemSeqId}</td>
-                <td colspan="2">${(product.internalName)!} <a href="/catalog/control/EditProduct?productId=${shipmentItem.productId!}" class="buttontext">${shipmentItem.productId!}</a></td>
+                <td colspan="2">${(product.internalName)!} <a href="<@ofbizUrl controlPath="/catalog/control">EditProduct?productId=${shipmentItem.productId!}</@ofbizUrl>" class="buttontext">${shipmentItem.productId!}</a></td>
                 <td>${shipmentItem.quantity?default("&nbsp;")}</td>
                 <td colspan="2">${shipmentItem.shipmentContentDescription?default("&nbsp;")}</td>
             </tr>
             <#list orderShipments as orderShipment>
                 <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                     <td>&nbsp;</td>
-                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="/ordermgr/control/orderview?orderId=${orderShipment.orderId!}&amp;externalLoginKey=${requestAttributes.externalLoginKey}" class="buttontext">${orderShipment.orderId!}</a>${orderShipment.orderItemSeqId!}</td>
+                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${orderShipment.orderId!}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>" class="buttontext">${orderShipment.orderId!}</a>${orderShipment.orderItemSeqId!}</td>
                     <td>&nbsp;</td>
                     <td>${orderShipment.quantity!}</td>
                     <td>&nbsp;</td>
@@ -54,7 +54,7 @@ under the License.
             <#list itemIssuances as itemIssuance>
                 <tr valign="middle"<#if alt_row> class="alternate-row"</#if>>
                     <td>&nbsp;</td>
-                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="/ordermgr/control/orderview?orderId=${itemIssuance.orderId!}&amp;externalLoginKey=${requestAttributes.externalLoginKey}" class="buttontext">${itemIssuance.orderId!}</a>${itemIssuance.orderItemSeqId!}</td>
+                    <td><span class="label">${uiLabelMap.ProductOrderItem}</span> <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${itemIssuance.orderId!}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>" class="buttontext">${itemIssuance.orderId!}</a>${itemIssuance.orderItemSeqId!}</td>
                     <td><span class="label">${uiLabelMap.ProductInventory}</span> <a href="<@ofbizUrl>EditInventoryItem?inventoryItemId=${itemIssuance.inventoryItemId!}</@ofbizUrl>" class="buttontext">${itemIssuance.inventoryItemId!}</a></td>
                     <td>${itemIssuance.quantity!}</td>
                     <td>${itemIssuance.issuedDateTime!}</td>
diff --git a/applications/product/template/shipment/WeightPackage.ftl b/applications/product/template/shipment/WeightPackage.ftl
index 54ebe28..9eea363 100644
--- a/applications/product/template/shipment/WeightPackage.ftl
+++ b/applications/product/template/shipment/WeightPackage.ftl
@@ -38,8 +38,8 @@ under the License.
               <ul>
                 <#list invoiceIds as invoiceId>
                   <li>
-                    ${uiLabelMap.CommonNbr}<a href="/accounting/control/invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${invoiceId}</a>
-                    (<a href="/accounting/control/invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
+                    ${uiLabelMap.CommonNbr}<a href="<@ofbizUrl controlPath="/accounting/control">invoiceOverview?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${invoiceId}</a>
+                    (<a href="<@ofbizUrl controlPath="/accounting/control">invoice.pdf?invoiceId=${invoiceId}${StringUtil.wrapString(externalKeyParam)}</@ofbizUrl>" target="_blank" class="buttontext">${uiLabelMap.CommonPdf}</a>)
                   </li>
                 </#list>
               </ul>
diff --git a/applications/product/template/store/EditProductStoreSurveys.ftl b/applications/product/template/store/EditProductStoreSurveys.ftl
index 0ccf95f..50e821a 100644
--- a/applications/product/template/store/EditProductStoreSurveys.ftl
+++ b/applications/product/template/store/EditProductStoreSurveys.ftl
@@ -39,7 +39,7 @@ under the License.
               <tr valign="middle"<#if alt_row>class="alternate-row"</#if>>
                 <td>${surveyType.get("description",locale)}</td>
                 <td>${storeSurvey.groupName!}</td>
-                <td><a href="/content/control/EditSurvey?surveyId=${storeSurvey.surveyId}" class="buttontext">${survey.description?default("[" + survey.surveyId + "]")}</a></td>
+                <td><a href="<@ofbizUrl controlPath="/content/control">EditSurvey?surveyId=${storeSurvey.surveyId}</@ofbizUrl>" class="buttontext">${survey.description?default("[" + survey.surveyId + "]")}</a></td>
                 <td>${storeSurvey.productId?default("${uiLabelMap.CommonNA}")}</td>
                 <td>${storeSurvey.productCategoryId?default("${uiLabelMap.CommonNA}")}</td>
                 <td>${storeSurvey.fromDate!?string}</td>
diff --git a/applications/product/template/store/EditProductStoreWebSites.ftl b/applications/product/template/store/EditProductStoreWebSites.ftl
index 032bc06..e78c712 100644
--- a/applications/product/template/store/EditProductStoreWebSites.ftl
+++ b/applications/product/template/store/EditProductStoreWebSites.ftl
@@ -21,7 +21,7 @@ under the License.
         <h3>${uiLabelMap.PageTitleEditProductStoreWebSites}</h3>
     </div>
     <div class="screenlet-body">
-      <a href="/content/control/EditWebSite?productStoreId=${productStoreId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}" class="buttontext">${uiLabelMap.ProductCreateNewProductStoreWebSite}</a>
+      <a href="<@ofbizUrl controlPath="/content/control">EditWebSite?productStoreId=${productStoreId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>" class="buttontext">${uiLabelMap.ProductCreateNewProductStoreWebSite}</a>
         <table cellspacing="0" class="basic-table">
             <tr class="header-row">
               <td>${uiLabelMap.ProductWebSiteId}</td>
@@ -33,7 +33,7 @@ under the License.
               <#assign rowClass = "2">
               <#list storeWebSites as webSite>
                 <tr valign="middle"<#if "1" == rowClass> class="alternate-row"</#if>>
-                  <td><a href="/content/control/EditWebSite?webSiteId=${webSite.webSiteId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}" class="buttontext">${webSite.siteName!} [${webSite.webSiteId}]</a></td>
+                  <td><a href="<@ofbizUrl controlPath="/content/control">EditWebSite?webSiteId=${webSite.webSiteId}&amp;externalLoginKey=${requestAttributes.externalLoginKey}</@ofbizUrl>" class="buttontext">${webSite.siteName!} [${webSite.webSiteId}]</a></td>
                   <td>${webSite.httpHost?default('&nbsp;')}</td>
                   <td>${webSite.httpPort?default('&nbsp;')}</td>
                   <td align="center">
diff --git a/applications/workeffort/template/calendar/CalendarEventContent.ftl b/applications/workeffort/template/calendar/CalendarEventContent.ftl
index 9526fcc..22d4272 100644
--- a/applications/workeffort/template/calendar/CalendarEventContent.ftl
+++ b/applications/workeffort/template/calendar/CalendarEventContent.ftl
@@ -18,13 +18,13 @@ under the License.
 -->
 
 <#if "PROD_ORDER_HEADER" == workEffort.workEffortTypeId>
-  <a href="/manufacturing/control/ShowProductionRun?productionRunId=${workEffort.workEffortId}" class="event">
+  <a href="<@ofbizUrl controlPath="/manufacturing/control">ShowProductionRun?productionRunId=${workEffort.workEffortId}</@ofbizUrl>" class="event">
     ${workEffort.workEffortId}
   </a>
   &nbsp;${workEffort.workEffortName?default("Undefined")}
   <#if workOrderItemFulfillments?has_content>
     <#list workOrderItemFulfillments as workOrderItemFulfillment>
-      <br/>${uiLabelMap.OrderOrderId}: <a href="/ordermgr/control/orderview?orderId=${workOrderItemFulfillment.orderId}" class="event">${workOrderItemFulfillment.orderId} / ${workOrderItemFulfillment.orderItemSeqId}</a>
+      <br/>${uiLabelMap.OrderOrderId}: <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${workOrderItemFulfillment.orderId}</@ofbizUrl>" class="event">${workOrderItemFulfillment.orderId} / ${workOrderItemFulfillment.orderItemSeqId}</a>
       <#assign orderItemAndShipGroupAssocs = EntityQuery.use(delegator).from("OrderHeaderItemAndShipGroup").where("orderId", workOrderItemFulfillment.orderId!, "orderItemSeqId", workOrderItemFulfillment.orderItemSeqId!).queryList()!/>
       <#list orderItemAndShipGroupAssocs as orderItemAndShipGroupAssoc>
         <#if orderItemAndShipGroupAssoc.shipByDate?has_content>
@@ -34,13 +34,13 @@ under the License.
     </#list>
   </#if>
 <#elseif "PROD_ORDER_TASK" == workEffort.workEffortTypeId>
-  <a href="/manufacturing/control/ShowProductionRun?productionRunId=${workEffort.workEffortParentId}" class="event">
+  <a href="<@ofbizUrl controlPath="/manufacturing/control">ShowProductionRun?productionRunId=${workEffort.workEffortParentId}</@ofbizUrl>" class="event">
     ${workEffort.workEffortParentId} / ${workEffort.workEffortId}
   </a>
   &nbsp;${workEffort.workEffortName?default("Undefined")}<#if workEffort.reservPersons??>&nbsp;Persons:${workEffort.reservPersons}</#if>
   <#if parentWorkOrderItemFulfillments?has_content>
     <#list parentWorkOrderItemFulfillments as parentWorkOrderItemFulfillment>
-      <br/>${uiLabelMap.OrderOrderId}: <a href="/ordermgr/control/orderview?orderId=${parentWorkOrderItemFulfillment.orderId}" class="event">${parentWorkOrderItemFulfillment.orderId} / ${parentWorkOrderItemFulfillment.orderItemSeqId}</a>
+      <br/>${uiLabelMap.OrderOrderId}: <a href="<@ofbizUrl controlPath="/ordermgr/control">orderview?orderId=${parentWorkOrderItemFulfillment.orderId}</@ofbizUrl>" class="event">${parentWorkOrderItemFulfillment.orderId} / ${parentWorkOrderItemFulfillment.orderItemSeqId}</a>
       <#assign orderItemAndShipGroupAssocs = EntityQuery.use(delegator).from("OrderHeaderItemAndShipGroup").where("orderId", parentWorkOrderItemFulfillment.orderId!, "orderItemSeqId", parentWorkOrderItemFulfillment.orderItemSeqId!).queryList()!/>
       <#list orderItemAndShipGroupAssocs as orderItemAndShipGroupAssoc>
         <#if orderItemAndShipGroupAssoc.shipByDate?has_content>
diff --git a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/RequestHandler.java b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/RequestHandler.java
index 18b6dae..9956de5 100644
--- a/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/RequestHandler.java
+++ b/framework/webapp/src/main/java/org/apache/ofbiz/webapp/control/RequestHandler.java
@@ -1066,6 +1066,10 @@ public class RequestHandler {
     }
 
     public String makeLink(HttpServletRequest request, HttpServletResponse response, String url, boolean fullPath, boolean secure, boolean encode) {
+        return makeLink(request, response, url, fullPath, secure, encode, "");
+    }
+
+    public String makeLink(HttpServletRequest request, HttpServletResponse response, String url, boolean fullPath, boolean secure, boolean encode, String targetControlPath) {
         WebSiteProperties webSiteProps = null;
         try {
             webSiteProps = WebSiteProperties.from(request);
@@ -1109,8 +1113,12 @@ public class RequestHandler {
                 return null;
             }
         }
-        // create the path to the control servlet
-        String controlPath = (String) request.getAttribute("_CONTROL_PATH_");
+
+        String controlPath = targetControlPath;
+        if (UtilValidate.isEmpty(controlPath)){
+            // create the path to the control servlet
+            controlPath = (String) request.getAttribute("_CONTROL_PATH_");
+        }
 
         //If required by webSite parameter, surcharge control path
         if (webSiteProps.getWebappPath() != null) {
diff --git a/themes/tomahawk/template/AppBarClose.ftl b/themes/tomahawk/template/AppBarClose.ftl
index af35581..7475102 100644
--- a/themes/tomahawk/template/AppBarClose.ftl
+++ b/themes/tomahawk/template/AppBarClose.ftl
@@ -85,7 +85,7 @@ under the License.
     <li <#if companyListSize?default(0) &lt;= 1>class="language"</#if>><a href="<@ofbizUrl>ListLocales</@ofbizUrl>">${uiLabelMap.CommonLanguageTitle}</a></li>
     <#if userLogin?exists>
       <#if userLogin.partyId?exists>
-        <li class="user"><a href="/partymgr/control/viewprofile?partyId=${userLogin.partyId}${externalKeyParam!}">${userName}</a>&nbsp;&nbsp;&nbsp;&nbsp;</li>
+        <li class="user"><a href="<@ofbizUrl controlPath="/partymgr/control">viewprofile?partyId=${userLogin.partyId}${externalKeyParam!}</@ofbizUrl>">${userName}</a>&nbsp;&nbsp;&nbsp;&nbsp;</li>
         <#assign size = companyListSize?default(0)>
         <#if size &gt; 1>
             <#assign currentCompany = delegator.findOne("PartyNameView", {"partyId" : organizationPartyId}, false)>