SVN: Zope/branches/2.13/src/OFS/dtml/properties.dtml - fixed some HTML issues

Yvo Schubbe <[email protected]>
Newsgroups gmane.comp.web.zope.cvs
Message-ID <[email protected]>
Log message for revision 120838:
  - fixed some HTML issues
  - related cleanup

Changed:
  UU  Zope/branches/2.13/src/OFS/dtml/properties.dtml

-=-
Modified: Zope/branches/2.13/src/OFS/dtml/properties.dtml
===================================================================
--- Zope/branches/2.13/src/OFS/dtml/properties.dtml	2011-03-10 08:49:03 UTC (rev 120837)
+++ Zope/branches/2.13/src/OFS/dtml/properties.dtml	2011-03-10 09:49:23 UTC (rev 120838)
@@ -56,69 +56,74 @@
 
 <dtml-in propertyMap mapping>
 <dtml-let type="not _.has_key('type') and 'string' or type"
-          pdesc="propertyDescription(id)">
+          pdesc="propertyDescription(id)"
+          charset_tag="REQUEST['management_page_charset_tag']">
 <tr title="&dtml-pdesc;">
   <td align="left" valign="top" width="16">
   <dtml-if "'d' in _['sequence-item'].get('mode', 'awd')">
-  <input type="checkbox" name="_ids:<dtml-var "REQUEST['management_page_charset_tag']">string:list" value="&dtml-id;"
-   id="cb-&dtml-id;">
+  <input type="checkbox" name="_ids:&dtml-charset_tag;string:list"
+   value="&dtml-id;" id="cb-&dtml-id;" />
   <dtml-else>
   </dtml-if>
   </td>
   <td align="left" valign="top">
   <div class="form-label">
-  <label for="cb-&dtml-id;"><dtml-var "propertyLabel(id)" html_quote></label>
+  <dtml-if "'d' in _['sequence-item'].get('mode', 'awd')">
+  <label for="cb-&dtml-id;">
+  <dtml-else>
+  <label>
+  </dtml-if>
+  <dtml-var "propertyLabel(id)" html_quote></label>
   </div>
   </td>
   <td align="left" valign="top">
-
   <dtml-if "'w' in _['sequence-item'].get('mode', 'awd')">
   <dtml-if "type == 'int'">
   <input type="text" name="&dtml-id;:&dtml-type;"
-   size="35" value="<dtml-if "hasProperty(id)"><dtml-var "'%s' % getProperty(id)" html_quote></dtml-if>">
+   size="35" value="<dtml-if "hasProperty(id)"><dtml-var
+    "'%s' % getProperty(id)" html_quote></dtml-if>" />
   <dtml-elif "type == 'long'">
   <input type="text" name="&dtml-id;:&dtml-type;" size="35"
-   value="<dtml-if "hasProperty(id)"><dtml-var "('%s' % getProperty(id))" html_quote></dtml-if>">
+   value="<dtml-if "hasProperty(id)"><dtml-var
+    "('%s' % getProperty(id))" html_quote></dtml-if>" />
   <dtml-elif "type in ('float', 'date')">
-  <input type="text" name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">&dtml-type;" size="35"
-   value="<dtml-var "getProperty(id)" html_quote>">
+  <input type="text" name="&dtml-id;:&dtml-charset_tag;&dtml-type;" size="35"
+   value="<dtml-var "getProperty(id)" html_quote>" />
   <dtml-elif "type in ['string','ustring']">
-  <input type="text" name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">&dtml-type;" size="35"
-   value="<dtml-var "getProperty(id)" html_quote>">
+  <input type="text" name="&dtml-id;:&dtml-charset_tag;&dtml-type;" size="35"
+   value="<dtml-var "getProperty(id)" html_quote>" />
   <dtml-elif "type=='boolean'">
-  <input type="checkbox" name="&dtml-id;:boolean" size="35"
-   <dtml-if "getProperty(id)">CHECKED</dtml-if>>
+  <input type="checkbox" name="&dtml-id;:&dtml-type;" size="35"
+   <dtml-if "getProperty(id)">checked="checked"</dtml-if> />
   <dtml-elif "type in ['tokens','utokens']">
-  <input type="text" name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">&dtml-type;" size="35"
-   value="<dtml-in "getProperty(id)">&dtml-sequence-item; </dtml-in>">
+  <input type="text" name="&dtml-id;:&dtml-charset_tag;&dtml-type;" size="35"
+   value="<dtml-in "getProperty(id)">&dtml-sequence-item; </dtml-in>" />
   <dtml-elif "type in ['text','utext']">
-  <textarea class="form-element" name="&dtml-id;:<dtml-var
-   "REQUEST['management_page_charset_tag']">&dtml-type;"
+  <textarea class="form-element" name="&dtml-id;:&dtml-charset_tag;&dtml-type;"
    rows="6" cols="35"><dtml-var "getProperty(id)" html_quote></textarea>
   <dtml-elif "type in ['lines','ulines']">
-  <textarea class="form-element" name="&dtml-id;:<dtml-var
-   "REQUEST['management_page_charset_tag']">&dtml-type;" rows="6"
-   cols="35"><dtml-in "getProperty(id)">&dtml-sequence-item;<dtml-if
+  <textarea class="form-element" name="&dtml-id;:&dtml-charset_tag;&dtml-type;"
+   rows="6" cols="35"><dtml-in "getProperty(id)">&dtml-sequence-item;<dtml-if
    sequence-end><dtml-else><dtml-var "'\n'"></dtml-if></dtml-in></textarea>
 
   <dtml-elif "type=='selection'">
 
     <dtml-if "hasProperty(select_variable)">
     <div class="form-element">
-    <select name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">text">
+    <select name="&dtml-id;:&dtml-charset_tag;text">
       <dtml-in "getProperty(select_variable)">
          <option
-          <dtml-if "_['sequence-item']==getProperty(id)">SELECTED</dtml-if>
+          <dtml-if "_['sequence-item']==getProperty(id)">selected="selected"</dtml-if>
           >&dtml-sequence-item;</option>
       </dtml-in>
     </select>
     </div>
     <dtml-elif "_.has_key(select_variable)">
     <div class="form-element">
-    <select name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">text">
+    <select name="&dtml-id;:&dtml-charset_tag;text">
       <dtml-in "_[select_variable]">
          <option
-          <dtml-if "_['sequence-item']==getProperty(id)">SELECTED</dtml-if>
+          <dtml-if "_['sequence-item']==getProperty(id)">selected="selected"</dtml-if>
           >&dtml-sequence-item;</option>
       </dtml-in>
     </select>
@@ -133,24 +138,24 @@
 
     <dtml-if "hasProperty(select_variable)">
     <div class="form-element">
-    <select name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">list:string" multiple
+    <select name="&dtml-id;:&dtml-charset_tag;list:string" multiple="multiple"
       size="<dtml-var "_.min(7, _.len(getProperty(select_variable)))">">
       <dtml-in "getProperty(select_variable)">
          <option<dtml-if 
          "getProperty(id) and (_['sequence-item'] in getProperty(id))"
-         > SELECTED</dtml-if
+         > selected="selected"</dtml-if
          >>&dtml-sequence-item;</option>
       </dtml-in>
     </select>
     </div>
     <dtml-elif "_.has_key(select_variable)">
     <div class="form-element">
-    <select name="&dtml-id;:<dtml-var "REQUEST['management_page_charset_tag']">list:string" multiple
+    <select name="&dtml-id;:&dtml-charset_tag;list:string" multiple="multiple"
       size="<dtml-var "_.min(7, _.len(_[select_variable]))">">
       <dtml-in "_[select_variable]">
          <option<dtml-if 
          "getProperty(id) and (_['sequence-item'] in getProperty(id))"
-         > SELECTED</dtml-if
+         > selected="selected"</dtml-if
          >>&dtml-sequence-item;</option>
       </dtml-in>
     </select>
@@ -198,13 +203,15 @@
   <td>
   <dtml-comment>
   This needs some community review before exposing it officially.
-  <input type="submit" name="manage_propertyTypeForm:method" value="Change Names/Types">
+  <input type="submit" name="manage_propertyTypeForm:method"
+   class="form-element" value="Change Names/Types" />
   </dtml-comment>
   </td>
 <dtml-else>
+  </div>
+  </td>
   <td>&nbsp;</td>
 </dtml-if>
-  </td>
 </tr>
 </table>
 
@@ -222,7 +229,8 @@
 
 <dtml-if property_extensible_schema__>
 
-<form action="<dtml-var "REQUEST.URL1" html_quote>/manage_addProperty" method="post">
+<form action="<dtml-var "REQUEST.URL1" html_quote>/manage_addProperty"
+ method="post">
 
 <p class="form-help">
 To add a new property, enter a name, type and value for the new 
@@ -237,7 +245,9 @@
   </div>
   </td>
   <td align="left" valign="top">
-  <input type="text" name="id:<dtml-var "REQUEST['management_page_charset_tag']">string" size="30" value=""/>
+  <input type="text" name="id:<dtml-var
+   "REQUEST['management_page_charset_tag']">string"
+   size="30" value="" />
   </td>
   <td align="left" valign="top" class="form-label">
   Type
@@ -251,7 +261,7 @@
       <option>int</option>
       <option>lines</option>
       <option>long</option>
-      <option selected>string</option>
+      <option selected="selected">string</option>
       <option>text</option>
       <option>tokens</option>
       <dtml-if "REQUEST['management_page_charset'] == 'UTF-8'">
@@ -272,11 +282,11 @@
   Value
   </div>
   </td>
-  <td colspan=2 align="left" valign="top">
+  <td colspan="2" align="left" valign="top">
   <dtml-if "REQUEST['management_page_charset'] == 'UTF-8'">
-    <input type="text" name="value:UTF-8:ustring" size="30" />   
-  <dtml-else>   
-     <input type="text" name="value:string" size="30" />   
+    <input type="text" name="value:UTF-8:ustring" size="30" />
+  <dtml-else>
+    <input type="text" name="value:string" size="30" />
   </dtml-if> 
   </td>
   <td align="right" valign="top">


Property changes on: Zope/branches/2.13/src/OFS/dtml/properties.dtml
___________________________________________________________________
Deleted: cvs2svn:cvs-rev
   - 1.17

_______________________________________________
Zope-Checkins maillist  -  [email protected]
https://mail.zope.org/mailman/listinfo/zope-checkins
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.