I have a string of Html and it contains varied Html but includes this
<span style="display:block;position:fixed;width:100%;height:2000px;background-color:rgba(0,0,0,0);z-index:9999!important;top:0;left:0;cursor:default;"></span>
This will seem strange, but I only want to remove specific items within the style attribute (For all Html elements). For example I want to remove
position:fixed and z-index:9999!important; and top:0; and left:0;
To name a few, but keep everything else. Now the issue is, it's not necessarily position:fixed; it could be position:absolute; or whatever. Just as it could be z-index:9998; or top:20; etc...
I need to be able to remove style elements by their key, so position:*anything* and top:*anything* etc.... AND also do this in a non-case sensitive manner. So it would get POSITION:*anything* or PoSition:*anything*
Is there a way to achieve this using the Html Agility Pack?