Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 64835
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T18:51:08+00:00 2026-05-10T18:51:08+00:00

Please advise how to scrape AJAX pages.

  • 0

Please advise how to scrape AJAX pages.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T18:51:08+00:00Added an answer on May 10, 2026 at 6:51 pm

    Overview:

    All screen scraping first requires manual review of the page you want to extract resources from. When dealing with AJAX you usually just need to analyze a bit more than just simply the HTML.

    When dealing with AJAX this just means that the value you want is not in the initial HTML document that you requested, but that javascript will be exectued which asks the server for the extra information you want.

    You can therefore usually simply analyze the javascript and see which request the javascript makes and just call this URL instead from the start.


    Example:

    Take this as an example, assume the page you want to scrape from has the following script:

    <script type='text/javascript'> function ajaxFunction() { var xmlHttp; try   {   // Firefox, Opera 8.0+, Safari   xmlHttp=new XMLHttpRequest();   } catch (e)   {   // Internet Explorer   try     {     xmlHttp=new ActiveXObject('Msxml2.XMLHTTP');     }   catch (e)     {     try       {       xmlHttp=new ActiveXObject('Microsoft.XMLHTTP');       }     catch (e)       {       alert('Your browser does not support AJAX!');       return false;       }     }   }   xmlHttp.onreadystatechange=function()     {     if(xmlHttp.readyState==4)       {       document.myForm.time.value=xmlHttp.responseText;       }     }   xmlHttp.open('GET','time.asp',true);   xmlHttp.send(null);   } </script> 

    Then all you need to do is instead do an HTTP request to time.asp of the same server instead. Example from w3schools.


    Advanced scraping with C++:

    For complex usage, and if you’re using C++ you could also consider using the firefox javascript engine SpiderMonkey to execute the javascript on a page.

    Advanced scraping with Java:

    For complex usage, and if you’re using Java you could also consider using the firefox javascript engine for Java Rhino

    Advanced scraping with .NET:

    For complex usage, and if you’re using .Net you could also consider using the Microsoft.vsa assembly. Recently replaced with ICodeCompiler/CodeDOM.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Please advise if you can. I am building an SMS web service API that
Please advise how to pass parameters into a function called using setInterval . My
Could someone please advise the current best practice around Date and Calendar types. When
I'm not sure how to approach this SQL statement so please advise, even if
I need to display a progress of loading of item's children. Please advise how
Please kindly advise on benchmarks used to test a C and C++ allocator? Benchmarks
Please advise on how to merge two results in to one using SQL Server
Please advise me the difference between two ways of declaration of java constructor public
please advise on the following, and if you were to do something different please
Please advise whether I am hallucinating... I hope so because I can't get tables

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.