Advertisement
Guest User

Untitled

a guest
Sep 13th, 2016
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.43 KB | None | 0 0
  1. <?php
  2. $url="http://smslane.com/vendorsms/pushsms.aspx?user=abc&password=xyz&msisdn=919898123456&sid=WebSMS&msg=Test message from SMSLane&fl=0";
  3. $ch = curl_init();
  4. curl_setopt( $ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; rv:1.7.3) Gecko/20041001 Firefox/0.10.1" );
  5. curl_setopt( $ch, CURLOPT_URL, $url );
  6. $content = curl_exec( $ch );
  7. $response = curl_getinfo( $ch );
  8. curl_close ( $ch );
  9. echo $content;
  10. ?>
  11.  
  12. <?php
  13. $ch = curl_init();
  14. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  15. curl_setopt($ch, CURLOPT_URL,
  16. 'http://your_server/response.php?foo=yes we can&baz=foo bar'
  17. );
  18. $content = curl_exec($ch);
  19. echo $content;
  20.  
  21. <?php
  22. print_r($_GET);
  23.  
  24. Array
  25. (
  26. [foo] => yes
  27. )
  28.  
  29. echo http_build_query(array(
  30. 'user'=>'abc',
  31. 'password'=>'xyz',
  32. 'msisdn'=>'1234',
  33. 'sid'=>'WebSMS',
  34. 'msg'=>'Test message from SMSLane',
  35. 'fl'=>0
  36. ));
  37.  
  38. curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
  39.  
  40. <?php
  41. print file_get_contents("http://some_server/some_file.php?some_args=true");
  42. ?>
  43.  
  44. <?php
  45. $ch = curl_init();
  46. curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
  47. curl_setopt($ch, CURLOPT_URL,'http://www.anydomain.com/anyapi.php?a=parameters');
  48. $content = curl_exec($ch);
  49. echo $content;
  50. ?>
  51.  
  52. $r = new HttpRequest('http://www.xencomsoftware.net/configurator/tracker/ip.php', HttpRequest::METH_GET);
  53. try {
  54. $r->send();
  55. echo $r->getResponseCode();
  56. if ($r->getResponseCode() == 200)
  57. {
  58. }
  59. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement