add function to get just the *value* of the attribute
This commit is contained in:
parent
af9d056d19
commit
67206b7904
@ -163,8 +163,16 @@
|
||||
}
|
||||
return $str;
|
||||
}
|
||||
|
||||
public function GetAttributeValue($name, $index = 0) : ?string
|
||||
{
|
||||
$attr = $this->GetAttribute($name, $index);
|
||||
if ($attr != null)
|
||||
return $attr->Value;
|
||||
return null;
|
||||
}
|
||||
|
||||
public function GetAttribute($name, $index = 0)
|
||||
public function GetAttribute($name, $index = 0) : ?MarkupAttribute
|
||||
{
|
||||
$i = 0;
|
||||
$last = null;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user