I need to search and retrieve nillable elements from an XSD scheme file. I tried treating the XSD scheme as a text file and iterating over the lines using "strpos" function with "nillable" to print the element line:
public function echo_nillables(){
$handle = fopen("filename.xsd");
if($handle){
while (($line = fgets($handle)) !== false){
if(strpos($line, "nillable"){
echo $line;
}
}
}
}
but the fgets seems to ignore the xsd scheme lines and handle them like blank lines, resulting nothing to be echoed. is there a workaround or any other way to do it? all I need is for the function to echo the nillable line/element. Thanks.