This repository has been archived by the owner on Apr 30, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsms.php
40 lines (34 loc) · 1.87 KB
/
sms.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
<?php
/*
* BY : KAKHA GIORGASHVILI / WWW.ANY.GE / [email protected] / @kakha13
*/
$username = @$_POST['user']; // მეტსახელი
$password = @$_POST['password']; // ჩვენი პაროლი
$to = @$_POST['to']; // ნომერი ვისაც ვუგზავნით
$text = @$_POST['text']; // ტექსტი რასაც ვაგზავნით
$loginUrl = 'http://www.magtifun.ge/index.php?page=11&lang=ge'; // მისამაართი სადაც უნდა გავიაროთ ავტორიზაცია
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $loginUrl);
curl_setopt($ch, CURLOPT_USERAGENT,'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/32.0.1700.107 Chrome/32.0.1700.107 Safari/537.36');
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, "user=$username&password=$password");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_COOKIESESSION, true);
curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookie-name'); // არ წაშალოთ მის გარეშე არ იმუშავებს
curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookie.txt'); // არ წაშალოთ მის გარეშე არ იმუშავებს
$answer = curl_exec($ch);
if (curl_error($ch)) {
echo curl_error($ch)."/n";
}
// გაგზავნა
curl_setopt($ch, CURLOPT_URL, 'http://www.magtifun.ge/scripts/sms_send.php');
curl_setopt($ch, CURLOPT_POSTFIELDS, "recipients=$to&message_body=$text <sms.any.ge>");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_COOKIESESSION, true);
curl_setopt($ch, CURLOPT_COOKIEJAR, 'cookie-name-send');
curl_setopt($ch, CURLOPT_COOKIEFILE, 'cookie-send.txt');
$answer = curl_exec($ch);
if (curl_error($ch)) {
echo curl_error($ch)."/n";
}
echo $answer;