Changeset 17545
- Timestamp:
- 2008-10-15T17:21:15+13:00 (16 years ago)
- Location:
- gsdl/trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
gsdl/trunk/common-src/src/lib/gsdltools.cpp
r16949 r17545 85 85 } 86 86 } 87 88 text_t xml_safe(const text_t &text_string) 89 { 90 text_t text_string_safe; 91 text_t::const_iterator here = text_string.begin(); 92 text_t::const_iterator end = text_string.end(); 93 while (here != end) { 94 if (*here == '&') text_string_safe += "&"; 95 else if (*here == '<') text_string_safe += "<"; 96 else if (*here == '>') text_string_safe += ">"; 97 else text_string_safe.push_back(*here); 98 ++here; 99 } 100 return text_string_safe; 101 } 102 87 103 88 104 // gsdl_system creates a new process for the cmd command (which -
gsdl/trunk/common-src/src/lib/gsdltools.h
r16895 r17545 52 52 inline text_t dm_js_safe (const text_t &instring) {text_t outstring; dm_js_safe(instring, outstring); return outstring;} 53 53 54 // Convert '&' to "&", '<' to "<", and '>' to ">" 55 text_t xml_safe(const text_t &text_string); 56 54 57 // gsdl_system creates a new process for the cmd command (which 55 58 // may contain arguments). -
gsdl/trunk/runtime-src/src/recpt/gtiaction.cpp
r13941 r17545 655 655 656 656 657 text_t gtiaction::xml_safe(const text_t &text_string)658 {659 text_t text_string_safe;660 text_t::const_iterator here = text_string.begin();661 text_t::const_iterator end = text_string.end();662 while (here != end) {663 if (*here == '&') text_string_safe += "&";664 else if (*here == '<') text_string_safe += "<";665 else if (*here == '>') text_string_safe += ">";666 else text_string_safe.push_back(*here);667 ++here;668 }669 670 return text_string_safe;671 }672 673 674 675 657 char* xml_get_attribute(const char** attributes, char* attribute_name) 676 658 { -
gsdl/trunk/runtime-src/src/recpt/gtiaction.h
r13692 r17545 107 107 text_t escape_all(text_t source_string, char character_to_escape); 108 108 109 text_t xml_safe(const text_t &text_string);110 111 109 void process_gti_submissions(displayclass& disp, cgiargsclass& args, ostream& logout, bool force_submission); 112 110
Note:
See TracChangeset
for help on using the changeset viewer.