Advertisement
Guest User

Untitled

a guest
Oct 2nd, 2016
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.59 KB | None | 0 0
  1. <?php
  2. $ch = curl_init();
  3.  
  4. curl_setopt($ch, CURLOPT_URL,"https://accesscenter.roundrockisd.org/HomeAccess/Account/LogOn");
  5. curl_setopt($ch, CURLOPT_POST, 1);
  6. curl_setopt($ch, CURLOPT_POSTFIELDS,
  7.             "Database=10&LogOnDetails.UserName=username&LogOnDetails.Password=password");
  8. curl_setopt($ch, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded'));
  9. curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie);
  10.  
  11. // receive server response ...
  12. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  13.  
  14. $server_output = curl_exec ($ch);
  15.  
  16. curl_close ($ch);
  17.  
  18. echo $server_output;
  19. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement