zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&", &name, &name_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &pind, &name, &name_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&", &pind, &name, &name_len, UG(utf8_conv)) == FAILURE) {
return;
}
}
#if LIBXML_VERSION >= 20605
-/* {{{ proto bool xmlwriter_set_indent(resource xmlwriter, bool indent)
+/* {{{ proto bool xmlwriter_set_indent(resource xmlwriter, bool indent) U
Toggle indentation on/off - returns FALSE on error */
PHP_FUNCTION(xmlwriter_set_indent)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_set_indent_string(resource xmlwriter, string indentString)
+/* {{{ proto bool xmlwriter_set_indent_string(resource xmlwriter, string indentString) U
Set string used for indenting - returns FALSE on error */
PHP_FUNCTION(xmlwriter_set_indent_string)
{
#endif
-/* {{{ proto bool xmlwriter_start_attribute(resource xmlwriter, string name)
+/* {{{ proto bool xmlwriter_start_attribute(resource xmlwriter, string name) U
Create start attribute - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_attribute)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_attribute(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_attribute(resource xmlwriter) U
End attribute - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_attribute)
{
/* }}} */
#if LIBXML_VERSION > 20617
-/* {{{ proto bool xmlwriter_start_attribute_ns(resource xmlwriter, string prefix, string name, string uri)
+/* {{{ proto bool xmlwriter_start_attribute_ns(resource xmlwriter, string prefix, string name, string uri) U
Create start namespaced attribute - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_attribute_ns)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sss",
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&s&",
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rsss", &pind,
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&s&", &pind,
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
/* }}} */
#endif
-/* {{{ proto bool xmlwriter_write_attribute(resource xmlwriter, string name, string content)
+/* {{{ proto bool xmlwriter_write_attribute(resource xmlwriter, string name, string content) U
Write full attribute - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_attribute)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss",
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
/* }}} */
#if LIBXML_VERSION > 20617
-/* {{{ proto bool xmlwriter_write_attribute_ns(resource xmlwriter, string prefix, string name, string uri, string content)
+/* {{{ proto bool xmlwriter_write_attribute_ns(resource xmlwriter, string prefix, string name, string uri, string content) U
Write full namespaced attribute - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_attribute_ns)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ssss",
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&s&s&",
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv),
+ &uri, &uri_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rssss", &pind,
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&s&s&", &pind,
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv),
+ &uri, &uri_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
/* }}} */
#endif
-/* {{{ proto bool xmlwriter_start_element(resource xmlwriter, string name)
+/* {{{ proto bool xmlwriter_start_element(resource xmlwriter, string name) U
Create start element tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_element)
{
/* }}} */
-/* {{{ proto bool xmlwriter_start_element_ns(resource xmlwriter, string prefix, string name, string uri)
+/* {{{ proto bool xmlwriter_start_element_ns(resource xmlwriter, string prefix, string name, string uri) U
Create start namespaced element tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_element_ns)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!ss",
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!&s&s&",
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs!ss", &pind,
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs!&s&s&", &pind,
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_element(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_element(resource xmlwriter) U
End current element - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_element)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_full_end_element(resource xmlwriter)
+/* {{{ proto bool xmlwriter_full_end_element(resource xmlwriter) U
End current element - returns FALSE on error */
PHP_FUNCTION(xmlwriter_full_end_element)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_element(resource xmlwriter, string name, string content)
+/* {{{ proto bool xmlwriter_write_element(resource xmlwriter, string name, string content) U
Write full element tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_element)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss",
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_element_ns(resource xmlwriter, string prefix, string name, string uri, string content)
+/* {{{ proto bool xmlwriter_write_element_ns(resource xmlwriter, string prefix, string name, string uri, string content) U
Write full namesapced element tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_element_ns)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!sss",
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s!&s&s&s&",
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs!sss", &pind,
- &prefix, &prefix_len, &name, &name_len, &uri, &uri_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs!&s&s&s&", &pind,
+ &prefix, &prefix_len, UG(utf8_conv), &name, &name_len, UG(utf8_conv), &uri, &uri_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_pi(resource xmlwriter, string target)
+/* {{{ proto bool xmlwriter_start_pi(resource xmlwriter, string target) U
Create start PI tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_pi)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_pi(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_pi(resource xmlwriter) U
End current PI - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_pi)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_pi(resource xmlwriter, string target, string content)
+/* {{{ proto bool xmlwriter_write_pi(resource xmlwriter, string target, string content) U
Write full PI tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_pi)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss",
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_cdata(resource xmlwriter)
+/* {{{ proto bool xmlwriter_start_cdata(resource xmlwriter) U
Create start CDATA tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_cdata)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_cdata(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_cdata(resource xmlwriter) U
End current CDATA - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_cdata)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_cdata(resource xmlwriter, string content)
+/* {{{ proto bool xmlwriter_write_cdata(resource xmlwriter, string content) U
Write full CDATA tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_cdata)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_raw(resource xmlwriter, string content)
+/* {{{ proto bool xmlwriter_write_raw(resource xmlwriter, string content) U
Write text - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_raw)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_text(resource xmlwriter, string content)
+/* {{{ proto bool xmlwriter_text(resource xmlwriter, string content) U
Write text - returns FALSE on error */
PHP_FUNCTION(xmlwriter_text)
{
/* }}} */
#if LIBXML_VERSION >= 20607
-/* {{{ proto bool xmlwriter_start_comment(resource xmlwriter)
+/* {{{ proto bool xmlwriter_start_comment(resource xmlwriter) U
Create start comment - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_comment)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_comment(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_comment(resource xmlwriter) U
Create end comment - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_comment)
{
#endif /* LIBXML_VERSION >= 20607 */
-/* {{{ proto bool xmlwriter_write_comment(resource xmlwriter, string content)
+/* {{{ proto bool xmlwriter_write_comment(resource xmlwriter, string content) U
Write full comment tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_comment)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_document(resource xmlwriter, string version, string encoding, string standalone)
+/* {{{ proto bool xmlwriter_start_document(resource xmlwriter, string version, string encoding, string standalone) U
Create document tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_document)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!s!", &version, &version_len, &enc, &enc_len, &alone, &alone_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!&s!&s!&",
+ &version, &version_len, UG(utf8_conv), &enc, &enc_len,
+ UG(utf8_conv), &alone, &alone_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|s!s!s!", &pind, &version, &version_len, &enc, &enc_len, &alone, &alone_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|s!&s!&s!&",
+ &pind, &version, &version_len, UG(utf8_conv), &enc, &enc_len,
+ UG(utf8_conv), &alone, &alone_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_document(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_document(resource xmlwriter) U
End current document - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_document)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_dtd(resource xmlwriter, string name, string pubid, string sysid)
+/* {{{ proto bool xmlwriter_start_dtd(resource xmlwriter, string name, string pubid, string sysid) U
Create start DTD tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_dtd)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s!s!", &name, &name_len, &pubid, &pubid_len, &sysid, &sysid_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&|s!&s!&",
+ &name, &name_len, UG(utf8_conv), &pubid, &pubid_len, UG(utf8_conv),
+ &sysid, &sysid_len, UG(utf8_conv)) == FAILURE) {
return;
}
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|s!s!", &pind, &name, &name_len, &pubid, &pubid_len, &sysid, &sysid_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&|s!&s!&",
+ &pind, &name, &name_len, UG(utf8_conv), &pubid, &pubid_len, UG(utf8_conv),
+ &sysid, &sysid_len, UG(utf8_conv)) == FAILURE) {
return;
}
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_dtd(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_dtd(resource xmlwriter) U
End current DTD - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_dtd)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_dtd(resource xmlwriter, string name, string pubid, string sysid, string subset)
+/* {{{ proto bool xmlwriter_write_dtd(resource xmlwriter, string name, string pubid, string sysid, string subset) U
Write full DTD tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_dtd)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s!s!s!", &name, &name_len, &pubid, &pubid_len, &sysid, &sysid_len, &subset, &subset_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&|s!&s!&s!&",
+ &name, &name_len, UG(utf8_conv), &pubid, &pubid_len, UG(utf8_conv),
+ &sysid, &sysid_len, UG(utf8_conv), &subset, &subset_len, UG(utf8_conv)) == FAILURE) {
return;
}
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|s!s!s!", &pind, &name, &name_len, &pubid, &pubid_len, &sysid, &sysid_len, &subset, &subset_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&|s!&s!&s!&",
+ &pind, &name, &name_len, UG(utf8_conv), &pubid, &pubid_len, UG(utf8_conv),
+ &sysid, &sysid_len, UG(utf8_conv), &subset, &subset_len, UG(utf8_conv)) == FAILURE) {
return;
}
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_dtd_element(resource xmlwriter, string name)
+/* {{{ proto bool xmlwriter_start_dtd_element(resource xmlwriter, string name) U
Create start DTD element - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_dtd_element)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_dtd_element(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_dtd_element(resource xmlwriter) U
End current DTD element - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_dtd_element)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_dtd_element(resource xmlwriter, string name, string content)
+/* {{{ proto bool xmlwriter_write_dtd_element(resource xmlwriter, string name, string content) U
Write full DTD element tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_dtd_element)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
/* }}} */
#if LIBXML_VERSION > 20608
-/* {{{ proto bool xmlwriter_start_dtd_attlist(resource xmlwriter, string name)
+/* {{{ proto bool xmlwriter_start_dtd_attlist(resource xmlwriter, string name) U
Create start DTD AttList - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_dtd_attlist)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_dtd_attlist(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_dtd_attlist(resource xmlwriter) U
End current DTD AttList - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_dtd_attlist)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_dtd_attlist(resource xmlwriter, string name, string content)
+/* {{{ proto bool xmlwriter_write_dtd_attlist(resource xmlwriter, string name, string content) U
Write full DTD AttList tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_dtd_attlist)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss",
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_start_dtd_entity(resource xmlwriter, string name, bool isparam)
+/* {{{ proto bool xmlwriter_start_dtd_entity(resource xmlwriter, string name, bool isparam) U
Create start DTD Entity - returns FALSE on error */
PHP_FUNCTION(xmlwriter_start_dtd_entity)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sb", &name, &name_len, &isparm) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&b", &name, &name_len, UG(utf8_conv), &isparm) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rsb", &pind, &name, &name_len, &isparm) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&b", &pind, &name, &name_len, UG(utf8_conv), &isparm) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
}
/* }}} */
-/* {{{ proto bool xmlwriter_end_dtd_entity(resource xmlwriter)
+/* {{{ proto bool xmlwriter_end_dtd_entity(resource xmlwriter) U
End current DTD Entity - returns FALSE on error */
PHP_FUNCTION(xmlwriter_end_dtd_entity)
{
}
/* }}} */
-/* {{{ proto bool xmlwriter_write_dtd_entity(resource xmlwriter, string name, string content)
+/* {{{ proto bool xmlwriter_write_dtd_entity(resource xmlwriter, string name, string content) U
Write full DTD Entity tag - returns FALSE on error */
PHP_FUNCTION(xmlwriter_write_dtd_entity)
{
zval *this = getThis();
if (this) {
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss",
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s&s&",
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
XMLWRITER_FROM_OBJECT(intern, this);
} else
#endif
{
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rss", &pind,
- &name, &name_len, &content, &content_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs&s&", &pind,
+ &name, &name_len, UG(utf8_conv), &content, &content_len, UG(utf8_conv)) == FAILURE) {
return;
}
ZEND_FETCH_RESOURCE(intern,xmlwriter_object *, &pind, -1, "XMLWriter", le_xmlwriter);
/* }}} */
#endif
-/* {{{ proto resource xmlwriter_open_uri(resource xmlwriter, string source)
+/* {{{ proto resource xmlwriter_open_uri(string source) U
Create new xmlwriter using source uri for output */
PHP_FUNCTION(xmlwriter_open_uri)
{
char *source;
char resolved_path[MAXPATHLEN + 1];
int source_len;
+ zend_uchar source_type;
#ifdef ZEND_ENGINE_2
zval *this = getThis();
void *ioctx;
#endif
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &source, &source_len) == FAILURE) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "t", &source, &source_len, &source_type) == FAILURE) {
WRONG_PARAM_COUNT;
return;
}
RETURN_FALSE;
}
+ if (source_type == IS_UNICODE) {
+ if (php_stream_path_encode(NULL, &source, &source_len, (UChar*)source, source_len, REPORT_ERRORS, NULL) == FAILURE) {
+ RETURN_FALSE;
+ }
+ }
+
valid_file = _xmlwriter_get_valid_file_path(source, resolved_path, MAXPATHLEN TSRMLS_CC);
+
if (!valid_file) {
+ if (source_type == IS_UNICODE) {
+ efree(source);
+ }
RETURN_FALSE;
}
#ifndef ZEND_ENGINE_2
ioctx = php_xmlwriter_streams_IO_open_write_wrapper(valid_file TSRMLS_CC);
if (ioctx == NULL) {
+ if (source_type == IS_UNICODE) {
+ efree(source);
+ }
RETURN_FALSE;
}
php_xmlwriter_streams_IO_close, ioctx, NULL);
if (out_buffer == NULL) {
+ if (source_type == IS_UNICODE) {
+ efree(source);
+ }
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to create output buffer");
RETURN_FALSE;
}
ptr = xmlNewTextWriterFilename(valid_file, 0);
#endif
+ if (source_type == IS_UNICODE) {
+ efree(source);
+ }
+
if (!ptr) {
RETURN_FALSE;
}
}
/* }}} */
-/* {{{ proto resource xmlwriter_open_memory()
+/* {{{ proto resource xmlwriter_open_memory() U
Create new xmlwriter using memory for string output */
PHP_FUNCTION(xmlwriter_open_memory)
{
}
/* }}} */
-/* {{{ proto string xmlwriter_output_memory(resource xmlwriter [,bool flush])
+/* {{{ proto string xmlwriter_output_memory(resource xmlwriter [,bool flush]) U
Output current buffer as string */
PHP_FUNCTION(xmlwriter_output_memory)
{
}
/* }}} */
-/* {{{ proto mixed xmlwriter_flush(resource xmlwriter [,bool empty])
+/* {{{ proto mixed xmlwriter_flush(resource xmlwriter [,bool empty]) U
Output current buffer */
PHP_FUNCTION(xmlwriter_flush)
{