<?php
echo'<div class="content"><div class="block">';
if(isset($_GET['sms'])){include_once ''.(str_replace("inc","", $_SERVER['DOCUMENT_ROOT'])).'/smsbill/sms_rubi.php';exit;}
if(isset($_GET['waytopay']))
{
  
  if($_GET['waytopay']!=NULL && in_array($_GET['waytopay'],Array(6,14,8,15,22,5,19,18,17,20)))
  {
    if(!empty($_POST['target']) && $_POST['target']>0)
    {
    echo'<form action="https://waytopay.org/merchant/index" method="post">
<input type=hidden name=MerchantId value=5950>
<input type=hidden name=OutSum value='.round($_POST['target'],2).'>
<input type=hidden name=InvId value=1>
<input type=hidden name=InvDesc value="Покупка рублей">
<input type=hidden name=IncCurr value='.hsc($_GET['waytopay']).'>
<input type=hidden name=IdUser value='.$ku['id'].'>
<input type=submit value="Перейти на сайт оплаты">
</form>';
    }
    else
    {
    echo '<div class="small title">Введите количество рублей.</div>
    <form action="" id="id2" method="post"><div style="width:0px;height:0px;position:absolute;left:-100px;top:-100px;overflow:hidden"><input type="hidden" name="id2_hf_0" id="id2_hf_0" /></div>
<input type="text" maxlength="12" value="" name="target"/>
<input type="submit" value="Подтвердить"/>
</form>';
    }
  }
  else
  {
    echo'<li><img src="/images/payment/i_qiwi.png" alt="o"> <a href="/payrub/waytopay-6">QIWI</a></li>
  <li><img src="/images/payment/i_ya.png" alt="o"> <a href="/payrub/waytopay-14">Яндекс.Деньги</a></li>
  <li><img src="/images/payment/i_zpay.png" alt="o"> <a href="/payrub/waytopay-8">Z-Payment</a></li>
  <li><img src="/images/payment/i_card.png" alt="o"> <a href="/payrub/waytopay-15">VISA / MasterCard</a></li>
  <li><img src="/images/payment/i_euroset.png" alt="o"> <a href="/payrub/waytopay-22">Евросеть</a></li>
  <li><img src="/images/payment/i_mc_megafon.png" alt="o"> <a href="/payrub/waytopay-19">Мегафон</a></li>
  <li><img src="/images/payment/i_mc_beeline.png" alt="o"> <a href="/payrub/waytopay-18">Билайн</a></li>
  <li><img src="/images/payment/i_mc_mts.png" alt="o"> <a href="/payrub/waytopay-17">МТС</a></li>
  <li><img src="/images/payment/i_mc_tele2.png" alt="o"> <a href="/payrub/waytopay-20">TELE 2</a></li>
  ';
  }
  include_once 'inc/foot.php';
}
echo '<img width="16" height="16" src="/images/icons/rub.png" alt="рубины" title="рубины"/>
<a href="/payrub/waytopay">WayToPay</a>
<br/><span class="minor">Смс, qiwi, мобильные платежи, яндекс-деньги, пластиковые карты, электронные деньги.</span><li><img width="16" height="16" src="/images/icons/rub.png" alt="рубины" title="рубины"/>
<a href="/payrub/sms">SMS</a></li>';
include_once 'inc/foot.php';
?>