Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

C# HTMLAgilityPack get content <script>

I want to get the contents of this script

<script language="javascript">
    //some content
</script>

How to do it using HTMLAgilityPack?

like image 676
user3857806 Avatar asked Feb 27 '26 17:02

user3857806


1 Answers

Did you try?

doc.DocumentNode.Descendants("script")

like image 84
Haja Maideen Avatar answered Mar 01 '26 07:03

Haja Maideen