I have copied code from here and there and managed to a little scraping of content, however the problem is that now except for IFrame no other module seamlessly takes my code with the existing skin behind, does this leave me with no other option than to create modules?
If so how do i make the module such that i can change the URL that needs to be scraped and will show different URLs on different pages.
Here my code below, where do i go from here ..
<%@ Import Namespace="System" %>
<%@ Import Namespace="System.Text.RegularExpressions" %>
<%@ Import Namespace="System.Text" %>
<%@ Import Namespace="System.Net" %>
<%@ Import Namespace="System.IO" %>
<script language="VB" runat="server">
Sub Page_Load(sender as Object, e as EventArgs)
'STEP 1: Create a WebClient instance
Dim objWebClient as New WebClient()
'STEP 2: Call the DownloadedData method
Const strURL as String = "www.dotnetnuke.com"
Dim aRequestedHTML() as Byte
aRequestedHTML = objWebClient.DownloadData(strURL)
'STEP 3: Convert the Byte array into a String
Dim objUTF8 as New UTF8Encoding()
Dim strRequestedHTML as String
strRequestedHTML = objUTF8.GetString(aRequestedHTML)
'WE'RE DONE! - display the string
dim pos1, pos2, pos3 as Int32
pos3 = 1200
strRequestedHTML = strRequestedHTML.replace("<img", "<hidden")
strRequestedHTML = strRequestedHTML.replace("<IMG", "<hidden")
lblHTMLOutput.Text = strRequestedHTML
End Sub
</script>
<html>
<body>
<h1></h1>
<p>
<asp:label id="lblHTMLOutput" runat="server" />
</body>
</html>