]> granicus.if.org Git - php/commitdiff
for now we let xml support build with versions older than 2.5.7, as we want
authorSterling Hughes <sterling@php.net>
Sat, 28 Jun 2003 07:46:03 +0000 (07:46 +0000)
committerSterling Hughes <sterling@php.net>
Sat, 28 Jun 2003 07:46:03 +0000 (07:46 +0000)
users to actually test this...

ext/simplexml/simplexml.c

index 19db746844243531fc590c7660fffafc4cbae285..10f24f7aa09438d1a6c78b5d1f2fa5105d18975b 100644 (file)
@@ -543,6 +543,8 @@ simplexml_ce_xpath_search(INTERNAL_FUNCTION_PARAMETERS)
 #define SCHEMA_BLOB 1
 #define SCHEMA_OBJECT 2
 
+#ifdef xmlSchemaParserCtxtPtr
+
 /* {{{ simplexml_ce_schema_validate_file()
  */
 static void
@@ -590,6 +592,8 @@ simplexml_ce_schema_validate(INTERNAL_FUNCTION_PARAMETERS, int type)
 }
 /* }}} */
 
+#endif
+
 /* {{{ simplexml_ce_register_ns()
  */
 static void
@@ -657,10 +661,12 @@ sxe_call_method(char *method, INTERNAL_FUNCTION_PARAMETERS)
 {
        if (!strcmp(method, "xsearch")) {
                simplexml_ce_xpath_search(INTERNAL_FUNCTION_PARAM_PASSTHRU);
+#ifdef xmlSchemaParserCtxtPtr
        } else if (!strcmp(method, "validate_schema_file")) {
                simplexml_ce_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, SCHEMA_FILE);    
        } else if (!strcmp(method, "validate_schema_buffer")) {
                simplexml_ce_schema_validate(INTERNAL_FUNCTION_PARAM_PASSTHRU, SCHEMA_BLOB);
+#endif
        } else if (!strcmp(method, "register_ns")) {
                simplexml_ce_register_ns(INTERNAL_FUNCTION_PARAM_PASSTHRU);
        } else if (!strcmp(method, "to_xml")) {