summaryrefslogtreecommitdiff
path: root/ext/dom/domimplementation.c
diff options
context:
space:
mode:
authorRob Richards <rrichards@php.net>2003-06-12 20:02:05 (GMT)
committerRob Richards <rrichards@php.net>2003-06-12 20:02:05 (GMT)
commit5b19e1ec92cc49031c069fcebdc570b5fa7a325b (patch)
treeaa34c7630feb6e43ff83003af1108c8e01a2e00c /ext/dom/domimplementation.c
parent48cc4a7be62173ae982e68349242966bb92a0544 (diff)
downloadphp-5b19e1ec92cc49031c069fcebdc570b5fa7a325b.tar.gz
add node->isSupported()
add domimplementation->hasFeature() add formatOutput property (extends DOM) call xmlFreeDoc when doc is no longer referenced rather than custom code save and savexml now format based on formatOutput property
Diffstat (limited to 'ext/dom/domimplementation.c')
-rw-r--r--ext/dom/domimplementation.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/ext/dom/domimplementation.c b/ext/dom/domimplementation.c
index 19db5a5..1a9f8a4 100644
--- a/ext/dom/domimplementation.c
+++ b/ext/dom/domimplementation.c
@@ -50,7 +50,18 @@ Since:
*/
PHP_FUNCTION(dom_domimplementation_has_feature)
{
- DOM_NOT_IMPLEMENTED();
+ int feature_len, version_len;
+ char *feature, *version;
+
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &feature, &feature_len, &version, &version_len) == FAILURE) {
+ return;
+ }
+
+ if (dom_has_feature(feature, version)) {
+ RETURN_TRUE;
+ } else {
+ RETURN_FALSE;
+ }
}
/* }}} end dom_domimplementation_has_feature */