graham23s Posted November 8, 2008 Share Posted November 8, 2008 Hi Guys, From tutorials and snippets of code i have this: <?php //////////////////////////////////////////////// // Auto Login with Curl //////////////////////////////////////////////// $email = '[email protected]'; $pass = 'test'; $curlPost = 'email=' . urlencode($email) . '&password=' . urlencode($pass) . '&submit=Login'; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, 'http://www.firstchoicepharmacy.co.uk/login.php'); curl_setopt($ch, CURLOPT_HEADER, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $curlPost); $data = curl_exec($ch); print("$data"); curl_close($ch); ?> (i used my own site for testing on) but when i execute the fields aren't filled in! is there something i am missing at all? cheers guys Graham Link to comment https://forums.phpfreaks.com/topic/131953-curl-testing-problem/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.