bool xml_add_attribute_text(char *name,char *value) { char str[5120]; if (!xml_writechar(' ')) return(FALSE); if (!xml_writetext(name)) return(FALSE); if (!xml_writetext("=\"")) return(FALSE); strcpy(str,value); xml_parsetagsinvalue(str); if (!xml_writetext(str)) return(FALSE); return(xml_writechar('\"')); }
bool xml_writetext(char *txt) { int i,sz; unsigned char *c; sz=(int)strlen(txt); if (sz==0) return(TRUE); c=(unsigned char*)txt; for ((i=0); (i<sz); i++) { if (!xml_writechar(*c++)) return(FALSE); } return(TRUE); }
bool xml_add_tagstart(char *name) { if (!xml_writechar('<')) return(FALSE); return(xml_writetext(name)); }