OSDN Git Service

Merge branch 'branch_0.12.0'
[modchxj/mod_chxj.git] / src / chxj_chtml20.c
index 7217648..a034ac3 100644 (file)
@@ -1721,15 +1721,20 @@ s_chtml20_start_form_tag(void *pdoc, Node *node)
     attr_action = chxj_encoding_parameter(r, attr_action, 0);
     attr_action = chxj_add_cookie_parameter(r, attr_action, chtml20->cookie);
     char *q;
+    char *new_query_string = NULL;
     q = strchr(attr_action, '?');
     if (q) {
-      new_hidden_tag = chxj_form_action_to_hidden_tag(r, doc->pool, attr_action, 0, post_flag);
+      new_hidden_tag = chxj_form_action_to_hidden_tag(r, doc->pool, attr_action, 0, post_flag, &new_query_string, CHXJ_TRUE);
       if (new_hidden_tag) {
         *q = 0;
       }
     }
     W_L(" action=\"");
     W_V(attr_action);
+    if (new_query_string) {
+      W_L("?");
+      W_V(new_query_string);
+    }
     W_L("\"");
   }
   if (attr_method) {