示例#1
0
 protected function GetAttributeFromElement(QueryPath\DOMQuery $Element, string $Query) : string
 {
     /*//
     	attempt to extract data from the specified attribute.
     	//*/
     switch ($Query) {
         case 'text':
             $DownloadURL = $Element->Text();
             break;
         default:
             $DownloadURL = $Element->Attr($Query);
             break;
     }
     return $DownloadURL;
 }