• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Skrypt homepay xml 7.6

Zacky

New Member
Joined
Jan 7, 2011
Messages
55
Reaction score
0
Location
Zielona Góra
Mam taki skrypt itemxml.php

Code:
<?php

function check_code($acc,$code)
{
global $config;
if(!preg_match("/^[A-Za-z0-9]{8}$/",$code)) return 0;
if(!(is_int($acc))) return 0;
$code=urlencode($code);
$handle=fopen("http://homepay.pl/sms/check_code.php?acc_id=".$acc."&code=".$code,'r');
$status=fgets($handle,8);
fclose($handle);
return $status;
}

$players_folder = 'E:\\OTS\\naruciak\\Naruto i Bleach\\data\\players\\'; //Folder Graczy w otsie, podwojne \\ miedzy folderami
if ($_POST['usluga'] == "item") //Nazwa uslugi dla ktorej bedzie dolny kod
{
$nick = $_POST['nick'];
$check = $_POST['check']; // podany kod sms
$item_id = '6527'; //ID itemy ktory ma zostac stworzony w DP
$file = $players_folder .$nick.'.xml';
if (file_exists($file)) {
//Sprawdzacz kodu
$acchomepay = "3379"; //Acc uslugi homepay.pl

$status = check_code($acchomepay,$check);
if ((empty($check)) || (empty($nick)))
{
$message = "Prosze wypelnic wszystkie pola.";
}
elseif ($status == 0)
{
$message = "Wpisany kod jest niepoprawny.";
}
else
{
$xml = simplexml_load_file($file);
$character = $xml->depots->depot->item->inside->addChild('item');
$character->addAttribute('id', $item_id);
$newplayerFile = $xml->asXML();
$open_file = fopen($file, 'w');
fwrite($open_file, $newplayerFile);
fclose($open_file);
$message = "Do twojego DP w głównym miescie zostal dodany item.";
}
}else{
$message = "<font color='red'><b>Nie isnieje taka postac!</b></font>";
}
}
else
{
echo "<p align='center'><font size='5' color='red'><b>Wpisz nick postaci i kod aktywacyjny w formularzu po lewej stronie!</b></font><br /></p>";
}
if (isset($message))
{
echo $message;
}
echo "<br><br><br><p align='right'><span style='font-size: 9px'><b><i>Skrypt stworzony i upubliczniony przez: Feniks</i></b></span></p>";
?>

I do tego folmularz
Code:
<form action='itemxml.php' method='post'>
<b>Treść sms : HPAY.GOLDOTS<br>
Numer : 7355<br>
Koszt : 3.69</b><br><br>
<b><span style="font-size: 11px">Nick Postaci</span></b>
<br />
<input style="cursor: pointer; border-style:dashed; color:white; background-color:#000000; width: 100px; text-align:center; font-size:9px; font-weight: bold;" type='text' name='nick' value=""/><br /><hr>
<b><span style="font-size: 11px">Kod Aktywacyjny</span></b>

<br />

<input style="cursor: pointer; border-style:dashed; color:white; background-color:#000000; width: 100px; text-align:center; font-size:9px; font-weight: bold;" type='text' name='check' maxlenght='8' value=""/><br /><hr>
<b><span style="font-size: 11px">Usługa</span></b><br />
<select style="cursor: pointer; border-style:dashed; color:white; background-color:#000000; width: 115px; text-align:center; font-size:9px; font-weight: bold;" name="usluga">
<option value="item">SMS COIN</option>
</select><br /><br />
<input style="text-align:center; font-size:9px; font-weight: bold;" type='submit' onclick="return confirm('UWAGA! Jeśli jesteś pewien, że postać jest wylogana kliknij OK.')" value='Zamawiam!'/></form></center>
<p align="right"><span style="font-size: 8px"><b>SMS Skrypt by <a target="_blank" href="http://sl.sytes.net/">Feniks</a> </b></span></p>

I nie działa jak należy.. System sprawdzania czy postać istnieje jest poprawny ale jak wpisuje kod dla usługi 3379 pokazuje że kod jest nie poprawny.. Co robić? Z góry dziękuje.
To jest alternatywny system homepay dla xml .

Wysyła error: Wpisany kod jest niepoprawny.
 
Last edited:
Back
Top