Skip to content

Instantly share code, notes, and snippets.

@Barneybook
Created June 5, 2012 04:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Barneybook/2872674 to your computer and use it in GitHub Desktop.
Save Barneybook/2872674 to your computer and use it in GitHub Desktop.
bot php file
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_URL, "haplay.no-ip.org/haplay/");
curl_setopt($ch, CURLOPT_HEADER, false);
curl_setopt($ch, CURLOPT_USERAGENT, "Google Bot");
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
$output = curl_exec($ch);
curl_close($ch);
echo $output;
$curl = curl_init();
curl_setopt ($curl, CURLOPT_URL, "http://www.mywebsite.com");
curl_setopt ($curl, CURLOPT_POST, 1);
curl_setopt ($curl, CURLOPT_POSTFIELDS, "usr=username&pswd=password");
curl_exec($curl);
echo curl_error($curl);
curl_close($curl);
?>
@Elviscartergh
Copy link

Can this bot work for any website

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment