تقييم الموضوع :
  • 0 أصوات - بمعدل 0
  • 1
  • 2
  • 3
  • 4
  • 5
[VB.NET] مشكلة في regex
#3
Heart 
(24-03-20, 12:57 PM)ابو روضة كتب :
كما قلت لحضرتك بالويب براوزر وبالسيلينام سهلة لآن الصفحة 
يجب تحميلها من داخل الصفحة لآنها مشفرة

For Each firas As HtmlElement In WebBrowser1.Document.GetElementsByTagName("a")
         If firas.GetAttribute("href").Contains("net-mkv") Then
             TextBox1.Text = firas.GetAttribute("href")
         End If
     Next



لكن أكيد هناك من سيعرف الحل وربنا يوفقك وانا والله حاولت معها كثير بأساليب أخرى
لكنى لم أعرف وهذه أخر محاولة كما طلبت بال HttpRequest

كود :
Dim request As HttpWebRequest = DirectCast(WebRequest.Create("http://underurl.com/5deb7cd1d3946"), HttpWebRequest)
       With request
           .Method = "GET"
           .Accept = "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9"
           .ContentType = "application/x-www-form-urlencoded; charset=UTF-8"
           .Host = "underurl.com"
           '.Referer = "no-referrer-when-downgrade"
           .UserAgent = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36"
       End With
       Dim response As HttpWebResponse = DirectCast(request.GetResponse(), HttpWebResponse)
       Dim Sr As New StreamReader(response.GetResponseStream())
       Dim Source As String = Sr.ReadToEnd()
       Sr.Close()
       RichTextBox1.Text = Source
       Dim doc As New HtmlAgilityPack.HtmlDocument
       doc.LoadHtml(Source)
       For Each n As HtmlAgilityPack.HtmlNode In doc.DocumentNode.SelectNodes("//div[@class='ng-scope']/a[@ng-href]")
           TextBox1.Text = (n.Attributes("href").Value)
       Next

الله يحفظك يا غالي  Heart
انا ايضا احوال جاهد للحصول على حل 
ان شاء الله الاخوة يساعدوننا في هذا
الرد }}}
تم الشكر بواسطة:


الردود في هذا الموضوع
مشكلة في regex - بواسطة trakktour - 24-03-20, 06:31 AM
RE: مشكلة في regex - بواسطة ابو روضة - 24-03-20, 12:57 PM
RE: مشكلة في regex - بواسطة trakktour - 24-03-20, 02:30 PM
RE: مشكلة في regex - بواسطة ابو روضة - 24-03-20, 02:30 PM
RE: مشكلة في regex - بواسطة trakktour - 24-03-20, 02:40 PM


التنقل السريع :


يقوم بقرائة الموضوع: بالاضافة الى ( 1 ) ضيف كريم