Blame view

account/admin/sms.php 759 Bytes
42868d70   andryeyev   Создал GIT
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
  <h1>Îòïðàâêà SMS</h1>
  <?php
  	//include_once($_SERVER['DOCUMENT_ROOT']."/account/mods/autorizator_admin.php");
  	//include_once($_SERVER['DOCUMENT_ROOT']."/account/class/class.report.php");
  include($_SERVER['DOCUMENT_ROOT']."/account/func/func.php");
  
  $sql = "SELECT * FROM catalogs_orders where id={$_GET['orderID']}";
  $r = mysql_query($sql);
  $row = mysql_fetch_assoc($r);
  
  if(isset($_POST['msg']) && strlen($_POST['msg'])>0){
  //$tel = "+380502360568";
  $tel = $row['phone'];
  sendSMS($tel,$_POST['msg']);
  print "Ñîîáùåíèå îòïðàâëåíî!";
  }
  
  //print_r($row);
  print "<form method='post' action=''>";
  print $row['phone'];
  print "<br /><textarea cols='50' rows='4' name='msg'></textarea>";
  print "<br /><input type='submit' value='Îòïðàâèòü' />";
  print'</form>';
  
  
  ?>