Remove element, but not innerHtml

Aug 23, 2012 at 2:11 PM
   
    <ul>
       <removeThis>    
            <li>
                <a type="link">
                    <img alt="" />
                </a>
            </li>
        </removeThis> 
    </ul>

if i wanted to remove that element how would i do it?

Sep 18, 2012 at 6:16 PM

Good luck

var Content = doc.DocumentNode.SelectSingleNode(@"//ul") ;
 var remcontent = doc.DocumentNode.SelectSingleNode(@"//removeThis"); 
     
         remcontent.Remove();