Skip to content
WJunction - Webmaster Forum

[PHP] A simpler way to log into wUpload using PHP and CURL

Status
Not open for further replies.

Vick

Banned
Banned
297
2011
72
PHP:
 A simpler way to log into wUpload using PHP and CURL

[CODE]<?php
/**
* Author: Vick@PHPCanyon.net
* Site  : www.PHPCanyon.net
* Date  : 26/11/2011
*/

// Variables to Post
$username = "vickkumar2011@gmail.com";
$password = "password";

$postvars = array(
    'email'=>$username,
    'redirect'=>"/",
    'password'=>$password,
    'rememberMe'=>"1"
); 

// Do Curl Request
$ch = curl_init(); 
curl_setopt($ch, CURLOPT_URL,'http://www.wupload.com/account/login'); 
curl_setopt($ch, CURLOPT_POST,1); 
curl_setopt ($ch, CURLOPT_COOKIEJAR, 'cookie.txt');
curl_setopt($ch, CURLOPT_POSTFIELDS, $postvars); 
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$result=curl_exec ($ch); 
curl_close ($ch); 

// Do Stuff with Results
echo $result;
?>[/CODE]
 

8 comments

Sorry for asking, but why we need this?

Instead of noobs asking coders to write them expensive bots, they can read and learn from snippets to write their own for free. And as this is 'dev area'. I don't see why I can't post snippets?
 
btw logging in to filesonic works the same way, you just have to change the url. Makes more sense than wupload, which is dying right now..
 
What LT said.

Also, I see how you're thinking but newbies will not learn. They expect full scripts that work out of the box with fancy GUIs, they have no idea what to do with snippets.
 
What LT said.

Also, I see how you're thinking but newbies will not learn. They expect full scripts that work out of the box with fancy GUIs, they have no idea what to do with snippets.

Nah xD newbs like me take such classes, modify it according to our needs and make scripts xD
 
Status
Not open for further replies.

About the author

V
Banned · Joined
297
Messages
72
Reactions
28
Points
Grow your business

Advertise on WJunction

Connect with an established international community of webmasters, hosting providers, developers and online entrepreneurs.

  • Premium & Premium+ Sticky
  • Dedicated section banners
  • Site-wide banner advertising
Explore advertising options
Back
Top Bottom