[Last Call] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 203
  • Last Modified:

Emulate this POST with a script

BElow is the header information, as reported by Mozilla's Live Headers add-in,  that a successful POST uses to retrieve a page through a form.  I am trying to emulate this POST with a script -  Perl, PHP, Python, C# - I am trying to use Perl.  I have done this many times before to get data from web pages but cannot get this one to work.  Are there any web scraping/ spidering gurus out there who can crack this?


POST /pls/screnn/awi_report HTTP/1.1
Host: oas.zacks.com
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv: Gecko/20060111 Firefox/
Accept: text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5
Accept-Language: en-us,en;q=0.5
Accept-Encoding: gzip,deflate
Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive: 300
Proxy-Connection: keep-alive
Referer: http://oas.zacks.com/pls/screnn/screening.show_categories?p_site_id=3&p_i=&p_o=&p_v=&p_comp_id=zcom2003&p_customer_id=
Cookie: ora_100m1.5k=6\20,21,24,25,115,30|select master_table.ticker,stock_data.EXCHANGE,stock_data.SECTOR_NAME,stock_data.X_IND,master_table.comp_name,prices.CLOSING from master_table,prices,stock_data where master_table.m_ticker=stock_data.m_ticker and master_table.m_ticker=prices.m_ticker AND upper(stock_data.MKT_VALUE) >= 100 AND upper(stock_data.VOLUME) >= 150000; TOTAL_POP=3; user_session=7a792c8b829032e1fc0d1a491b1e1927
Content-Type: application/x-www-form-urlencoded
Content-Length: 487
1 Solution
Based on the related question you posted last week, I'd say you should look at Perl's WWW::Mechanize module.


Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now