Hi :
I am using libxml2-2.6.8. I need to
validate an xml file against it's schema definations. It would be nice if when
validatity error occured, I could get more information about the failed
element.
The testSchema.c file uses fprintf as
callback function, I was wondering how do I define my own callback
function? I did something like this:
void error_func(void *ctxt, char *
msg)
{
printf("%s", msg);
}
but it didn't print out anyting, exectp "%s". So
how do i get the error message in the callback function? Am I able to get a
pointer to the failed element ?
Thank you!
chris, sun
|