diff --git a/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java b/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
index ab4f9e6366..3b2a85ec33 100644
--- a/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
+++ b/framework/widget/src/org/ofbiz/widget/form/MacroFormRenderer.java
@@ -2448,8 +2448,17 @@ public class MacroFormRenderer implements FormStringRenderer {
if (UtilValidate.isNotEmpty(targetBuffer.toString()) && targetBuffer.toString().toLowerCase().startsWith("javascript:")) {
targetType="plain";
}
- //FIXME need to change to macro
- WidgetWorker.makeHyperlinkString(writer, modelFormField.getHeaderLinkStyle(), targetType, targetBuffer.toString(), null, titleText, modelFormField, this.request, this.response, null, null);
+ StringWriter sr = new StringWriter();
+ WidgetWorker.makeHyperlinkString(sr, modelFormField.getHeaderLinkStyle(), targetType, targetBuffer.toString(), null, titleText, modelFormField, this.request, this.response, null, null);
+ String title = sr.toString().replace("\"", "\'");
+ sr = new StringWriter();
+ sr.append("<@renderHyperlinkTitle ");
+ sr.append(" name=\"");
+ sr.append(modelFormField.getModelForm().getName());
+ sr.append("\" title=\"");
+ sr.append(title);
+ sr.append("\" />");
+ executeMacro(sr.toString());
} else if (modelFormField.isSortField()) {
renderSortField (writer, context, modelFormField, titleText);
} else if (modelFormField.isRowSubmit()) {
@@ -2459,7 +2468,7 @@ public class MacroFormRenderer implements FormStringRenderer {
sr.append(modelFormField.getModelForm().getName());
sr.append("\" title=\"");
sr.append(titleText);
- sr.append("\" />");
+ sr.append("\" showSelectAll=\"Y\"/>");
executeMacro(sr.toString());
} else {
writer.append(titleText);
diff --git a/framework/widget/templates/foFormMacroLibrary.ftl b/framework/widget/templates/foFormMacroLibrary.ftl
index 51ca0e16f0..b1da0ca2cf 100644
--- a/framework/widget/templates/foFormMacroLibrary.ftl
+++ b/framework/widget/templates/foFormMacroLibrary.ftl
@@ -128,7 +128,7 @@ under the License.
<#macro renderFieldGroupOpen style id title collapsed collapsibleAreaId collapsible expandToolTip collapseToolTip>#macro>
<#macro renderFieldGroupClose style id title>#macro>
-<#macro renderHyperlinkTitle name title>#macro>
+<#macro renderHyperlinkTitle name title showSelectAll="N">#macro>
<#macro renderSortField style title linkUrl ajaxEnabled>#macro>
<#macro formatBoundaryComment boundaryType widgetType widgetName>#macro>
<#macro makeHiddenFormLinkAnchor linkStyle hiddenFormName event action imgSrc description><@renderField description />#macro>
diff --git a/framework/widget/templates/htmlFormMacroLibrary.ftl b/framework/widget/templates/htmlFormMacroLibrary.ftl
index 3c5ca314fc..8d82543b03 100644
--- a/framework/widget/templates/htmlFormMacroLibrary.ftl
+++ b/framework/widget/templates/htmlFormMacroLibrary.ftl
@@ -453,7 +453,7 @@ ${item.description}
#macro>
<#macro renderFieldGroupClose style id title><#if style?has_content || id?has_content || title?has_content>#if>#macro>
-<#macro renderHyperlinkTitle name title><#if title?has_content>${title}
#if>#macro>
+<#macro renderHyperlinkTitle name title showSelectAll="N"><#if title?has_content>${title}
#if><#if showSelectAll="Y">#if>#macro>
<#macro renderSortField style title linkUrl ajaxEnabled> class="${style}"#if> href="<#if ajaxEnabled?has_content && ajaxEnabled>javascript:ajaxUpdateAreas('${linkUrl}')<#else>${linkUrl}#if>">${title}#macro>
<#macro formatBoundaryComment boundaryType widgetType widgetName>#macro>
diff --git a/framework/widget/templates/textFormMacroLibrary.ftl b/framework/widget/templates/textFormMacroLibrary.ftl
index afcefdc173..9b4bc22640 100644
--- a/framework/widget/templates/textFormMacroLibrary.ftl
+++ b/framework/widget/templates/textFormMacroLibrary.ftl
@@ -17,7 +17,7 @@ specific language governing permissions and limitations
under the License.
-->
-<#macro renderField text><#if text?exists>${text}#if>#macro>
+<#macro renderField text><#if text?exists>"${text}"#if>#macro>
<#macro renderDisplayField idName description class alert inPlaceEditorId="" inPlaceEditorUrl="" inPlaceEditorParams="">
<@renderField description />
@@ -112,7 +112,7 @@ under the License.
<#macro renderFieldGroupOpen style id title collapsed collapsibleAreaId collapsible expandToolTip collapseToolTip>#macro>
<#macro renderFieldGroupClose style id title>#macro>
-<#macro renderHyperlinkTitle name title>#macro>
+<#macro renderHyperlinkTitle name title showSelectAll="N">#macro>
<#macro renderSortField style title linkUrl ajaxEnabled>#macro>
<#macro formatBoundaryComment boundaryType widgetType widgetName>#macro>
<#macro makeHiddenFormLinkAnchor linkStyle hiddenFormName event action imgSrc description><@renderField description />#macro>
diff --git a/framework/widget/templates/xmlFormMacroLibrary.ftl b/framework/widget/templates/xmlFormMacroLibrary.ftl
index 88618a61b0..4b754701c8 100644
--- a/framework/widget/templates/xmlFormMacroLibrary.ftl
+++ b/framework/widget/templates/xmlFormMacroLibrary.ftl
@@ -110,7 +110,7 @@ under the License.
<#macro renderFieldGroupOpen style id title collapsed collapsibleAreaId collapsible expandToolTip collapseToolTip>#macro>
<#macro renderFieldGroupClose style id title>#macro>
-<#macro renderHyperlinkTitle name title>#macro>
+<#macro renderHyperlinkTitle name title showSelectAll="N">#macro>
<#macro renderSortField style title linkUrl ajaxEnabled>#macro>
<#macro formatBoundaryComment boundaryType widgetType widgetName>#macro>
<#macro makeHiddenFormLinkAnchor linkStyle hiddenFormName event action imgSrc description><@renderField description />#macro>