cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

RE: help with cURL + PHP

From: Mladen Jovic <mladen.jovic_at_hotmail.com>
Date: Tue, 4 Nov 2014 10:28:53 +0100

So if i understand there is no easy way to fill up those inputs throught php even if i fill up manually CAPTCHA? :(

> From: scott_at_stopthatsnoring.com.au
> Date: Tue, 4 Nov 2014 19:01:10 +1030
> Subject: Re: help with cURL + PHP
> To: curl-and-php_at_cool.haxx.se
>
> I think the problem is more fundamental. cURL isn't useful for
> filling in forms. What cURL could do for you is to simulate sending
> ("POSTing") a completed form to the form target... ie simulate what
> happens after a human fills in the fields and then clicks the "Isci"
> button. You can read about the POST process here... it's a
> fundamental part of the internet :
> http://en.wikipedia.org/wiki/POST_(HTTP)
>
> So, can we do this with cURL in your application? Turns out to be
> pretty hard... it's not just a "normal" POST.
>
> If you examine the page source at
> https://raz.zav-zdruzenje.si/infocenter/Search.aspx you'll see that
> clicking the Isci button runs some javascript.... so you could dig
> into that javascript and see how it works, then simulate THAT with
> cURL. The javascript most likely carries out a POST, and probably
> some other processing... so you'd have to simulate the other
> processing in PHP and then do the POST with cURL. Of course you'd
> also need to get the captcha solved somehow... perhaps with a service
> like http://www.deathbycaptcha.com/
>
> An alternative approach, if you are happy to solve the captcha
> yourself and just want to save time filling in the other fields is to
> use a windows machine and control Internet Explorer through vb or vba.
> Here's a rough example to get you started :
> http://www.excely.com/excel-vba/ie-automation.shtml
>
> Good luck :)
>
> Scott

                                               

_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2014-11-04