OSDN Git Service

Merge branch 'branch_0.13.0' into branch_0.13.0-svn
authorkonn <konn@1a406e8e-add9-4483-a2c8-d8cac5b7c224>
Fri, 10 Apr 2009 13:07:57 +0000 (13:07 +0000)
committerkonn <konn@1a406e8e-add9-4483-a2c8-d8cac5b7c224>
Fri, 10 Apr 2009 13:07:57 +0000 (13:07 +0000)
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/modchxj/mod_chxj/branches/RELEASE_0_13_0@4774 1a406e8e-add9-4483-a2c8-d8cac5b7c224

src/chxj_chtml20.c
src/chxj_chtml30.c
src/chxj_ixhtml10.c

index 90c4692..3b24677 100644 (file)
@@ -1978,7 +1978,7 @@ s_chtml20_start_input_tag(void *pdoc, Node *node)
     W_L("\"");
   }
   if (attr_value) {
-    if (STRCASEEQ('s','S',"submit",type) || STRCASEEQ('r','R',"reset",type)) {
+    if (STRCASEEQ('s','S',"submit",attr_type) || STRCASEEQ('r','R',"reset",attr_type)) {
       apr_size_t value_len = strlen(attr_value);
       attr_value = chxj_conv_z2h(r, attr_value, &value_len, chtml20->entryp);
     }
index 27a70a9..eaa0374 100644 (file)
@@ -1870,8 +1870,8 @@ s_chtml30_start_input_tag(void *pdoc, Node *node)
     W_L("\"");
   }
   if (attr_value) {
-    if (STRCASEEQ('s','S',"submit",type) || STRCASEEQ('r','R',"reset",type)) {
-      apr_size_t value_len = strlen(attrvalue);
+    if (STRCASEEQ('s','S',"submit",attr_type) || STRCASEEQ('r','R',"reset",attr_type)) {
+      apr_size_t value_len = strlen(attr_value);
       attr_value = chxj_conv_z2h(r, attr_value, &value_len, chtml30->entryp);
     }
 
index 5b83d8b..401f043 100644 (file)
@@ -22,6 +22,7 @@
 #include "chxj_encoding.h"
 #include "chxj_url_encode.h"
 #include "chxj_str_util.h"
+#include "chxj_conv_z2h.h"
 
 
 #define GET_IXHTML10(X) ((ixhtml10_t *)(X))
@@ -1904,6 +1905,11 @@ s_ixhtml10_start_input_tag(void *pdoc, Node *node)
     W_L("\"");
   }
   if (attr_value) {
+    if (STRCASEEQ('s','S',"submit",attr_type) || STRCASEEQ('r','R',"reset",attr_type)) {
+      apr_size_t value_len = strlen(attr_value);
+      attr_value = chxj_conv_z2h(r, attr_value, &value_len, chtml20->entryp);
+    }
+
     W_L(" value=\"");
     W_V(chxj_add_slash_to_doublequote(doc->pool, attr_value));
     W_L("\"");
@@ -3726,6 +3732,7 @@ s_ixhtml10_text_tag(void* pdoc, Node* child)
   int          ii;
   int          tdst_len;
   request_rec* r;
+  apr_size_t  z2h_input_len;
 
   ixhtml10 = GET_IXHTML10(pdoc);
   doc   = ixhtml10->doc;
@@ -3776,6 +3783,9 @@ s_ixhtml10_text_tag(void* pdoc, Node* child)
       }
     }
   }
+  z2h_input_len = strlen(tdst);
+  tdst = chxj_conv_z2h(r, tdst, &z2h_input_len, ixhtml10->entryp);
+
   W_V(tdst);
   return ixhtml10->out;
 }