• 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!

Gesior zaypay report URL bugged config

ATT3

Intermediate OT User
Joined
Sep 22, 2010
Messages
512
Reaction score
100
Hello, I have been trying to solve this but simply couldnt.
I have found many threads like this which none of them seem to have answer..

As the title says my problem is ZayPay report URL bugged config.

When I enter http://gythium.net/zaypay_report.php

anyways.
I am using Gesior 0.4~

custom_scirpts folders are writeable.

config.php
Code:
<?php
$options[149743]['name'] = 'Buy 100 premium points';
$options[149743]['payalogue_id'] = 133957;
$options[149743]['price_id'] = 149743;
$options[149743]['price_key'] = 'fd752123d08dd57841d796cfabfac069';
$options[149743]['points'] = 100;

$options[149745]['name'] = 'Buy 200 premium points';
$options[149745]['payalogue_id'] = 133959;
$options[149745]['price_id'] = 149745;
$options[149745]['price_key'] = '5b772708f9ff9df125c5d9ca8dbf8f61';
$options[149745]['points'] = 200;

$options[149747]['name'] = 'Buy 300 premium points';
$options[149747]['payalogue_id'] = 133961;
$options[149747]['price_id'] = 149747;
$options[149747]['price_key'] = '04ca249aed4196669926ca779b3fd1b6';
$options[149747]['points'] = 300;

Everything should be correct above.


zaypay_report.php

Code:
<?php
if(!defined('INITIALIZED'))
    exit;


require_once('./custom_scripts/zaypay/config.php');

if(isset($_GET['payment_id']) && isset($_GET["price_setting_id"]) && isset($options[$_GET["price_setting_id"]]))
{
    $option = $options[$_GET["price_setting_id"]];
    $zaypay = new Zaypay($option['price_id'], $option['price_key']);
    $zaypay_info = $zaypay->show_payment($_GET['payment_id']);
    if($zaypay_info["payment"]["status"] == 'paid' && !file_exists('./custom_scripts/zaypay/used_codes/zay_id_' . $zaypay_info["payment"]["id"]. '.txt'))
    {
        $_acc = explode('=', $zaypay_info["payment"]["your-variables"]);
        $acc = $_acc[1];
        if(file_put_contents('./custom_scripts/zaypay/used_codes/zay_id_' . $zaypay_info["payment"]["id"]. '.txt' , 'account:' . $acc . ',amount-euro:' . $zaypay_info["payment"]["amount-euro"] . ',points:' . $option['points']) !== false)
        {
            $account = new Account($acc);
            if($account->isLoaded())
            {
                $account->set('premium_points', ($account->getCustomField('premium_points')+$option['points']));
                $account->save();
            }
            echo '*ok*';
            exit;
        }
        else
        {
            echo '*cannot save code to folder used_codes*';
            exit;
        }
    }
    else
    {
        echo '*code already used*';
        exit;
    }
}
echo '*bugged config*';
exit;


Just ask if you need more information, thanks.
 
Last edited:
Is there any issue with Zaypay or is it just about "bugged config"?

- - - Edited - - -

It's not like *bugged config* does anything fyi. :p
 
Is there any issue with Zaypay or is it just about "bugged config"?

- - - Edited - - -

It's not like *bugged config* does anything fyi. :p

Nope, theres not any problems with ZayPay, I need this to work for them to approve my site.

Also updated main post, forgot to add zaypay_report.php
 
Did you ever solve this? I'm also getting this bugged config thingy when i'm trying to get approved, he is telling me to fix that before he'll let me use zaypay.
 
Might aswell ask @Ninja since he has solved pretty much every question i have ever had related to anything.

my zaypay_report.php located in /www

PHP:
<?php
$_GET['subtopic'] = 'zaypay_report';
$_REQUEST['subtopic'] = 'zaypay_report';
include('index.php');

zaypay_report.php located in www/pages/

PHP:
<?php
if(!defined('INITIALIZED'))
    exit;

require_once('./custom_scripts/zaypay/config.php');

if(isset($_GET['payment_id']) && isset($_GET["price_setting_id"]) && isset($options[$_GET["price_setting_id"]]))
{
    $option = $options[$_GET["price_setting_id"]];
    $zaypay = new Zaypay($option['price_id'], $option['price_key']);
    $zaypay_info = $zaypay->show_payment($_GET['payment_id']);
    if($zaypay_info["payment"]["status"] == 'paid' && !file_exists('./custom_scripts/zaypay/used_codes/zay_id_' . $zaypay_info["payment"]["id"]. '.txt'))
    {
        $_acc = explode('=', $zaypay_info["payment"]["your-variables"]);
        $acc = $_acc[1];
        if(file_put_contents('./custom_scripts/zaypay/used_codes/zay_id_' . $zaypay_info["payment"]["id"]. '.txt' , 'account:' . $acc . ',amount-euro:' . $zaypay_info["payment"]["amount-euro"] . ',points:' . $option['points']) !== false)
        {
            $account = new Account($acc);
            if($account->isLoaded())
            {
                $account->set('premium_points', ($account->getCustomField('premium_points')+$option['points']));
                $account->save();
            }
            echo '*ok*';
            exit;
        }
        else
        {
            echo '*ERROR: cannot save code to folder used_codes, make that folder writeable*';
            exit;
        }
    }
    else
    {
        echo '*ok*';
        exit;
    }
}
echo '*ERROR: bugged config or someone try to hack*';
exit;

I don't know if zaypay.php located in www/classes is related to this? wouldn't let me post it because its huge. Any idea?
 
Back
Top