-----BEGIN PGP SIGNED MESSAGE-----
I don't think you'll get php to work with google unless you use the google
api - I heard that google has filtered out the php(and others) user-agent.
If you need more info on the google api just let me know.
On Friday 27 September 2002 07:25 pm, [EMAIL PROTECTED] wrote:
> I am trying to use curl to post data to a search engine and then
> return the results in a variable so I can manipulate it.
> I have tried this but it does not seam to work properly.
> This is just an example of how I am trying to do this I don't have
> to use google for the search engine just thought if I can get it
> working with this I can get it to work with others
> $ch = curl_init ("http://www.google.com/");
> curl_setopt ($ch, CURLOPT_POST, 1);
> $args="action=/search&hl=en&ie=UTF-8&oe=UTF-8&q=$word&btnG=Google Search";
> curl_setopt ($ch, CURLOPT_POSTFIELDS, $args);
> curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
> $data = curl_exec ($ch);
> curl_close ($ch);
> echo $data;
> There does not seam to be much info or examples on using curl with php
> is there anyplace that you know of that has more info than the manual
Design Specialist @ WebPower Design
"The web....the way you want it!"
"It said uses Windows 98 or better, so I loaded Linux!"
Registered Linux User #183202 using Register Linux System # 81891
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
-----END PGP SIGNATURE-----
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php