diff --git a/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_decorateHtmlRepresentation.xml b/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_decorateHtmlRepresentation.xml
new file mode 100644
index 0000000000000000000000000000000000000000..92a841fb0e3bd7c76fb6207745333de8d32eaa28
--- /dev/null
+++ b/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_decorateHtmlRepresentation.xml
@@ -0,0 +1,153 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <tuple>
+        <tuple>
+          <string>Products.PythonScripts.PythonScript</string>
+          <string>PythonScript</string>
+        </tuple>
+        <none/>
+      </tuple>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>Python_magic</string> </key>
+            <value>
+              <none/>
+            </value>
+        </item>
+        <item>
+            <key> <string>Script_magic</string> </key>
+            <value> <int>3</int> </value>
+        </item>
+        <item>
+            <key> <string>__ac_local_roles__</string> </key>
+            <value>
+              <none/>
+            </value>
+        </item>
+        <item>
+            <key> <string>_bind_names</string> </key>
+            <value>
+              <object>
+                <klass>
+                  <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
+                </klass>
+                <tuple/>
+                <state>
+                  <dictionary>
+                    <item>
+                        <key> <string>_asgns</string> </key>
+                        <value>
+                          <dictionary>
+                            <item>
+                                <key> <string>name_container</string> </key>
+                                <value> <string>container</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_context</string> </key>
+                                <value> <string>context</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_m_self</string> </key>
+                                <value> <string>script</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_subpath</string> </key>
+                                <value> <string>traverse_subpath</string> </value>
+                            </item>
+                          </dictionary>
+                        </value>
+                    </item>
+                  </dictionary>
+                </state>
+              </object>
+            </value>
+        </item>
+        <item>
+            <key> <string>_body</string> </key>
+            <value> <string encoding="cdata"><![CDATA[
+
+htmlrepr=\'<div style="background-color:white;color:black;">%s</div>\' % context.getHtmlRepresentation()\n
+context.log(context.REQUEST[\'URL\'])\n
+if context.portal_type==\'Spreadsheet\':\n
+  htmlrepr=htmlrepr.replace(\'<A HREF="#table\',\'<A HREF="%s#table\' % context.REQUEST[\'URL\'])\n
+return htmlrepr\n
+
+
+]]></string> </value>
+        </item>
+        <item>
+            <key> <string>_code</string> </key>
+            <value>
+              <none/>
+            </value>
+        </item>
+        <item>
+            <key> <string>_filepath</string> </key>
+            <value>
+              <none/>
+            </value>
+        </item>
+        <item>
+            <key> <string>_params</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>errors</string> </key>
+            <value>
+              <tuple/>
+            </value>
+        </item>
+        <item>
+            <key> <string>func_code</string> </key>
+            <value>
+              <object>
+                <klass>
+                  <global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
+                </klass>
+                <tuple/>
+                <state>
+                  <dictionary>
+                    <item>
+                        <key> <string>co_argcount</string> </key>
+                        <value> <int>0</int> </value>
+                    </item>
+                    <item>
+                        <key> <string>co_varnames</string> </key>
+                        <value>
+                          <tuple>
+                            <string>_getattr_</string>
+                            <string>context</string>
+                            <string>htmlrepr</string>
+                            <string>_getitem_</string>
+                          </tuple>
+                        </value>
+                    </item>
+                  </dictionary>
+                </state>
+              </object>
+            </value>
+        </item>
+        <item>
+            <key> <string>func_defaults</string> </key>
+            <value>
+              <none/>
+            </value>
+        </item>
+        <item>
+            <key> <string>id</string> </key>
+            <value> <string>DMS_decorateHtmlRepresentation</string> </value>
+        </item>
+        <item>
+            <key> <string>warnings</string> </key>
+            <value>
+              <tuple/>
+            </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_htmlRepresentation/html_representation.xml b/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_htmlRepresentation/html_representation.xml
index f259ba0338d0fe1f5ff3fe6a200a723952e62dec..dcf905730fce0fd6a31d5f868d81e164088b2545 100644
--- a/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_htmlRepresentation/html_representation.xml
+++ b/bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/DMS_htmlRepresentation/html_representation.xml
@@ -299,11 +299,7 @@
       <dictionary>
         <item>
             <key> <string>_text</string> </key>
-            <value> <string encoding="cdata"><![CDATA[
-
-python:\'<div style="background-color:white;color:black;">%s</div>\' % here.getHtmlRepresentation()
-
-]]></string> </value>
+            <value> <string>here/DMS_decorateHtmlRepresentation</string> </value>
         </item>
       </dictionary>
     </pickle>