Index: trunk/extensions/SemanticForms/includes/SF_FormPrinter.inc |
— | — | @@ -475,10 +475,7 @@ |
476 | 476 | } else |
477 | 477 | $cur_value = ''; |
478 | 478 | if ($cur_value && ! is_array($cur_value)) { |
479 | | - $cur_value = Sanitizer::safeEncodeAttribute($cur_value); |
480 | | - // undo the encoding of ampersands and a few other characters |
481 | | - $cur_value = str_replace('&', '&', $cur_value); |
482 | | - $cur_value = str_replace(array('{', '|', '}'), array('{', '|', '}'), $cur_value); |
| 479 | + $cur_value = str_replace('"', '"', $cur_value); |
483 | 480 | } |
484 | 481 | |
485 | 482 | if ($cur_value == null) { |
— | — | @@ -495,10 +492,7 @@ |
496 | 493 | } else |
497 | 494 | $cur_value = ''; |
498 | 495 | if ($cur_value) { |
499 | | - $cur_value = Sanitizer::safeEncodeAttribute($cur_value); |
500 | | - // undo the encoding of ampersands and a few other characters |
501 | | - $cur_value = str_replace('&', '&', $cur_value); |
502 | | - $cur_value = str_replace(array('{', '|', '}'), array('{', '|', '}'), $cur_value); |
| 496 | + $cur_value = str_replace('"', '"', $cur_value); |
503 | 497 | } |
504 | 498 | } |
505 | 499 | |
— | — | @@ -1061,7 +1055,14 @@ |
1062 | 1056 | // English and can't be changed |
1063 | 1057 | function confirm_text(evt) { |
1064 | 1058 | // show this confirmation message only if the user didn't |
1065 | | - // click on a form element |
| 1059 | + // click on a form element. |
| 1060 | + // unfortunately, Internet Explorer doesn't pass in any value to |
| 1061 | + // this function, so we can't tell if it was called when a user |
| 1062 | + // hit "Save page", etc. - in the interest of not causing user |
| 1063 | + // confusion, we'll just do nothing if the browser is IE |
| 1064 | + if (typeof evt == 'undefined') { |
| 1065 | + return; |
| 1066 | + } |
1066 | 1067 | if (evt.target.className != "createbox") { |
1067 | 1068 | return "Changes to the form will not be saved."; |
1068 | 1069 | } |
— | — | @@ -1091,7 +1092,7 @@ |
1092 | 1093 | global $wgParser; |
1093 | 1094 | $new_text = $wgParser->preprocess(str_replace( "{{!}}", "|", $form_page_title ), $this->mPageTitle, new ParserOptions()); |
1094 | 1095 | return array($form_text, "/*<![CDATA[*/ $javascript_text /*]]>*/", |
1095 | | - $data_text, $form_page_title, $generated_page_name); |
| 1096 | + $data_text, $new_text, $generated_page_name); |
1096 | 1097 | } |
1097 | 1098 | |
1098 | 1099 | /** |