Caputring data sent from another web site

Results 1 to 2 of 2

Thread: Caputring data sent from another web site

  1. #1
    Paul Higginbottom Guest

    Default Caputring data sent from another web site

    I hope this isn&#039t really dumb, I&#039m new to ASP, but I can&#039t find any references to what I want in the books I have.<BR>I want to send a query off to a web site which I don&#039t control and don&#039t have any tie ups with and capture what comes back in such a way that I can create variables to use inside my ASP prog.<BR>I don&#039t mind if I can only capture the HTML source data, I could wade through that and discover the data that I want ?

  2. #2
    Join Date
    Dec 1969

    Default RE: Caputring data sent from another web site

    Hey Paul.<BR><BR>It&#039s not dumb at all.<BR><BR>There are a couple of ways to retrieve information from other servers.<BR><BR>There&#039s a component called ASPTear by Christoph Wille. You can go here for documentation and download:<BR><BR><BR>There&#039s also something called Microsoft Internet Transfer Control. It&#039s supposed to be a part of ASP, but I never got it to work, so I can&#039t really help you if you can&#039t figure it out. You can read about it here:<BR><BR><BR>Then you can choose to write your own component in Java. The people at have written two articles about that. You can find the first one here:<BR><BR><BR>And the second one here:<BR><BR><BR>And finally, there&#039s a component called XMLHTTP. This is what I use. This component comes with Microsoft Internet Explorer 5, so if you have that installed on your server, you shouldn&#039t need any additional downloads. It&#039s actually supposed to be used to grab XML files from other servers, but it can actually be used to retrieve any kind of file from another server.<BR><BR>If you want to test if the XMLHTTP component works on your server, this piece of code should tell you what you want to know:<BR><BR>&#060;%<BR> Set osbjXML = Server.CreateObject("Microsoft.XMLHTTP")<BR><BR> "GET", "", False<BR> objXML.send()<BR><BR> MyString = objXML.responseText<BR><BR> Set objXML = Nothing<BR><BR> Response.Write MyString<BR>%&#062;<BR><BR>Put this in any file with the extension "asp" on your server, e.g. "altavista.asp". If it works, it will load and show you the page, just like if it was in fact a page on your own server.<BR>If it doesn&#039t work, you will get an error in line 2, that will look something like this:<BR><BR>Server object error &#039ASP 0177 : 800401f3&#039<BR>Server.CreateObject Failed<BR>/altavista.asp, line 2<BR>800401f3<BR><BR>If you see this, it probably means that you don&#039t have Microsoft Internet Explorer 5 installed on your server.<BR><BR>If it does work and you would like more documentation about this component, you can find it here:<BR><BR><BR>I hope this is enough to get you started. If you get stuck at any time, please e-mail me and I&#039ll help you the best I can.<BR><BR>Take care,<BR>Lasse.<BR>( )<BR><BR>Note: Please use e-mail if you want to contact me again, since I don&#039t come to this forum very often. Don&#039t expect a reply if you ask me anything on here.<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts