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

curl-and-php

Please advice me (fwd)

From: Daniel Stenberg <daniel-curl_at_haxx.se>
Date: Mon, 22 Aug 2005 07:57:55 +0200 (CEST)

Forwarded to the mailing list.

-- 
  Commercial curl and libcurl Technical Support: http://haxx.se/curl.html
---------- Forwarded message ----------
Date: Sat, 20 Aug 2005 18:35:10 +0530
From: Vibranarayanan <vibranarayanan.mohan_at_dci.in>
To: curl-and-php-owner_at_cool.haxx.se
Subject: Please advice me
Dear Sir/Madam
I need to do the Auction sniping website. I m new to cURL.
I. has decided to go with cURL I am using below code.
My objective is
1. User will give the trademe.co.nz web site user name and password. I have
to verify that user name and password are correct or not.if correct i have
to use their account details to bid latter.
2. If we come to bidding i have to login to tradme.co.nz using user
details.(login via cURL etc..) and place the bid.(Bid product detail
will give by user)
I am using below code for login checking. this take me to trademe.co.nz.
i have to do the user validation in my website path. No need to go to
trademe.co.nz.
My Code is
code 1
<?php
         $ch = curl_init("http://www.trademe.co.nz/struc
<http://www.google.com/url?sa=D&q=http://www.trademe.co.nz/structure/login.a
sp> ture/login.asp");
         curl_setopt($ch, CURLOPT_POST, 1);
         curl_setopt($ch, CURLOPT_POSTFIELDS,
"email=phpvibra_at_gmail.com&password=vibrakln")-;
         curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
         $test = curl_exec($ch);
         curl_close($ch);
         print $test;
?>
code 2
<?   $ch = curl_init("http://www.trademe.co.nz/structure/login.asp");
         curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); //return results inline
         curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
         $result = curl_exec($ch);
         echo $result;
         //curl_close($ch);
// $test = file("http://www.snip.pl/en/my/ebay/
<http://www.google.com/url?sa=D&q=http://www.snip.pl/en/my/ebay/> ");
  //print_r($test);
?>
<script language="javascript">
document.signin.email.value="p-hpvi...
<http://groups.google.co.in/groups/unlock?msg=be72ecf2bd53d216&_done=/group/
Professional-PHP/browse_thread/thread/8fb72866cd2b5f83%3Fhl%3Den>
@gmail.com";
document.signin.password.value-="vibrakln";
document.signin.action="http://www.trademe.co.nz/struc
<http://www.google.com/url?sa=D&q=http://www.trademe.co.nz/structure/login.a
sp> ture/login.asp"
document.signin.submit();
</script>
Please advice me
Thanks and regards
vibra
Received on 2005-08-22