[MKDoc-commit] Updated start date markup to add labels and do the selected option in a

chris at mkdoc.demon.co.uk chris at mkdoc.demon.co.uk
Thu Oct 21 16:50:49 BST 2004


Log Message:
-----------
Updated start date markup to add labels and do the selected option in a different way.
These same updates also need applying to the end date, I'll sort this tomorrow.

Tags:
----
mkdoc-1-6

Modified Files:
--------------
    mkd/templates/editor/timerange:
        en.html

-------------- next part --------------
Index: en.html
===================================================================
RCS file: /var/spool/cvs/mkd/templates/editor/timerange/Attic/en.html,v
retrieving revision 1.1.2.2
retrieving revision 1.1.2.3
diff -Ltemplates/editor/timerange/en.html -Ltemplates/editor/timerange/en.html -u -r1.1.2.2 -r1.1.2.3
--- templates/editor/timerange/en.html
+++ templates/editor/timerange/en.html
@@ -182,112 +182,197 @@
       >
         The start of this time range.
       </em>
-      <label
-        for="timerange_from_date"
+      <span
         xml:lang="en"
         lang="en"
         dir="ltr"
-        petal:attributes="for name_from_date"
-      >Start Date</label>
+      >Start Date</span>
       <br />
       
+      <label
+        for="timerange_from_month"
+        petal:attributes="for name_from_month"
+      >Month</label>
       <select 
         id="timerange_from_month"
         name="timerange_from_month"
         title="Select the start month."
-        petal:attributes="name name_from_month; id name_from_month"
+        petal:attributes="name name_from_month; 
+                          id   name_from_month;"
       >
-        <option value="">Month</option>
-        <option 
-          petal:repeat="month self/month_select string:from"
-          petal:attributes="selected month/is_selected;
-                            value    month/value;
-                            title    month/label"
-          petal:content="month/label"
-        ></option>
+        <div 
+          petal:repeat="month self/month_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    month/value;
+                              title    month/value"
+            petal:content="month/label"
+            petal:condition="true: month/is_selected"
+          >January</option>
+          <option 
+            petal:attributes="value    month/value;
+                              title    month/value"
+            petal:content="month/label"
+            petal:condition="false: month/is_selected"
+          >Feburary</option>
+        </div>
       </select>
 
+      <label
+        for="timerange_from_day"
+        petal:attributes="for name_from_day"
+      >Day</label>
       <select 
         id="timerange_from_day"
         name="timerange_from_day"
         title="Select the start day."
-        petal:attributes="name name_from_day; id name_from_day"
+        petal:attributes="name name_from_day; 
+                          id   name_from_day;"
       >
-        <option value="">Day</option>
-        <option 
-          petal:repeat="day self/day_select string:from"
-          petal:attributes="selected day/is_selected;
-                            value    day/value;
-                            title    day/label"
-          petal:content="day/label"
-        ></option>
+        <div
+          petal:repeat="day self/day_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    day/value;
+                              title    day/value"
+            petal:content="day/label"
+            petal:condition="true: day/is_selected"
+          >01</option>
+          <option 
+            petal:attributes="value    day/value;
+                              title    day/value"
+            petal:content="day/label"
+            petal:condition="false: day/is_selected"
+          >02</option>
+        </div>
       </select>
 
+      <label
+        for="timerange_from_year"
+        petal:attributes="for name_from_year" 
+      >Year</label>
       <select 
         id="timerange_from_year"
         name="timerange_from_year"
         title="Select the start year."
-        petal:attributes="name name_from_year; id name_from_year"
+        petal:attributes="name name_from_year; 
+                          id   name_from_year;"
       >
-        <option value="">Year</option>
-        <option 
-          petal:repeat="year self/year_select string:from"
-          petal:attributes="selected year/is_selected;
-                            value    year/value;
-                            title    year/label"
-          petal:content="year/label"
-        ></option>
+        <div
+          petal:repeat="year self/year_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    year/value;
+                              title    year/value"
+            petal:content="year/label"
+            petal:condition="true: year/is_selected"
+          >2004</option>
+          <option 
+            petal:attributes="value    year/value;
+                              title    year/value"
+            petal:content="year/label"
+            petal:condition="false: year/is_selected"
+          >2004</option>
+        </div>
       </select>
-
-      at 
-
+ 
+      <label
+        for="timerange_from_hour"
+        petal:attributes="for name_from_hour" 
+      >Hour</label>
       <select 
         id="timerange_from_hour"
         name="timerange_from_hour"
         title="Select the start hour."
-        petal:attributes="name name_from_hour; id name_from_hour"
+        petal:attributes="name name_from_hour; 
+                          id   name_from_hour;"
       >
-        <option value="">Hour</option>
-        <option 
-          petal:repeat="hour self/hour_select string:from"
-          petal:attributes="selected hour/is_selected;
-                            value    hour/value;
-                            title    hour/label"
-          petal:content="hour/label"
-        ></option>
-      </select>
-
-      :
-      
+        <div
+          petal:repeat="hour self/hour_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    hour/value;
+                              title    hour/value"
+            petal:content="hour/label"
+            petal:condition="true: hour/is_selected"
+          >00</option>
+          <option 
+            petal:attributes="value    hour/value;
+                              title    hour/value"
+            petal:content="hour/label"
+            petal:condition="false: hour/is_selected"
+          >01</option>
+        </div>
+      </select>
+
+      <label 
+        for="timerange_from_minute"
+        petal:attributes="for name_from_minute" 
+      >Minute</label>
       <select 
         id="timerange_from_minute"
         name="timerange_from_minute"
         title="Select the start minute."
-        petal:attributes="name name_from_minute; id name_from_minute"
+        petal:attributes="name name_from_minute; 
+                          id   name_from_minute;"
       >
-        <option value="">Minute</option>
-        <option 
-          petal:repeat="minute self/minute_select string:from"
-          petal:attributes="selected minute/is_selected;
-                            value    minute/value;
-                            title    minute/label"
-          petal:content="minute/label"
-        ></option>
+        <div
+          petal:repeat="minute self/minute_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    minute/value;
+                              title    minute/value"
+            petal:content="minute/label"
+            petal:condition="true: minute/is_selected"
+          >00</option>
+          <option 
+            petal:attributes="value    minute/value;
+                              title    minute/value"
+            petal:content="minute/label"
+            petal:condition="false: minute/is_selected"
+          >00</option>
+        </div>
       </select>
 
+      <label
+        for="timerange_from_tz"
+        petal:attributes="for name_from_tz"
+      >Time Zone</label>
       <select 
         id="timerange_from_tz"
         name="timerange_from_tz"
         title="Select the start tz."
-        petal:attributes="name name_from_tz; id name_from_tz"
+        petal:attributes="name name_from_tz; 
+                          id   name_from_tz;"
       >
-        <option 
-          petal:repeat="tz self/tz_select string:from"
-          petal:attributes="selected tz/is_selected;
-                            value    tz/value;
-                            title    tz/label"
-          petal:content="tz/label"
-        ></option>
+        <div
+          petal:repeat="tz self/tz_select --from"
+          petal:omit-tag=""
+        >
+          <option 
+            selected="selected"
+            petal:attributes="value    tz/value;
+                              title    tz/value"
+            petal:content="tz/label"
+            petal:condition="true: tz/is_selected"
+          >BST</option>
+          <option 
+            petal:attributes="value    tz/value;
+                              title    tz/value"
+            petal:content="tz/label"
+            petal:condition="false: tz/is_selected"
+          >GMT</option>
+        </div> 
       </select>
 
     </p>
@@ -302,13 +387,11 @@
       >
         The end of this time range.
       </em>
-      <label
-        for="timerange_to_date"
+      <span
         xml:lang="en"
         lang="en"
         dir="ltr"
-        petal:attributes="for name_to_date"
-      >End Date</label>
+      >End Date</span>
       <br />
       
       <select 
@@ -319,7 +402,7 @@
       >
         <option value="">Month</option>
         <option 
-          petal:repeat="month self/month_select string:to"
+          petal:repeat="month self/month_select --to"
           petal:attributes="selected month/is_selected;
                             value    month/value;
                             title    month/label"
@@ -335,7 +418,7 @@
       >
         <option value="">Day</option>
         <option 
-          petal:repeat="day self/day_select string:to"
+          petal:repeat="day self/day_select --to"
           petal:attributes="selected day/is_selected;
                             value    day/value;
                             title    day/label"
@@ -351,7 +434,7 @@
       >
         <option value="">Year</option>
         <option 
-          petal:repeat="year self/year_select string:to"
+          petal:repeat="year self/year_select --to"
           petal:attributes="selected year/is_selected;
                             value    year/value;
                             title    year/label"
@@ -369,7 +452,7 @@
       >
         <option value="">Hour</option>
         <option 
-          petal:repeat="hour self/hour_select string:to"
+          petal:repeat="hour self/hour_select --to"
           petal:attributes="selected hour/is_selected;
                             value    hour/value;
                             title    hour/label"
@@ -387,7 +470,7 @@
       >
         <option value="">Minute</option>
         <option 
-          petal:repeat="minute self/minute_select string:to"
+          petal:repeat="minute self/minute_select --to"
           petal:attributes="selected minute/is_selected;
                             value    minute/value;
                             title    minute/label"
@@ -402,7 +485,7 @@
         petal:attributes="name name_to_tz; id name_to_tz"
       >
         <option 
-          petal:repeat="tz self/tz_select string:to"
+          petal:repeat="tz self/tz_select --to"
           petal:attributes="selected tz/is_selected;
                             value    tz/value;
                             title    tz/label"


More information about the MKDoc-commit mailing list