Skip to content

Commit

Permalink
Version 1.7.4
Browse files Browse the repository at this point in the history
  • Loading branch information
cryptoapi committed Dec 20, 2015
1 parent 38c7fd8 commit 57754a5
Show file tree
Hide file tree
Showing 20 changed files with 40 additions and 31 deletions.
4 changes: 2 additions & 2 deletions COPYING
@@ -1,5 +1,5 @@
Copyright (c) 2014-2015 Delta Consultants
Copyright (c) 2014-2015 GoUrl.io Developers
Copyright (c) 2014-2016 Delta Consultants
Copyright (c) 2014-2016 GoUrl.io Developers

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 1 addition & 1 deletion Examples/example_basic.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Basic Example
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/api-php.html
*/
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-download-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example4 - Pay-Per-Download (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p2
* @live_demo https://gourl.io/lib/examples/pay-per-download-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-download.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example3 - Pay-Per-Download (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p2
* @live_demo https://gourl.io/lib/examples/pay-per-download.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-membership-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example12 - Pay-Per-Membership (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p6
* @live_demo https://gourl.io/lib/examples/pay-per-membership-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-membership.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example11 - Pay-Per-Membership (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p6
* @live_demo https://gourl.io/lib/examples/pay-per-membership.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-page-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example10 - Pay-Per-Page Access (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p5
* @live_demo https://gourl.io/lib/examples/pay-per-page-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-page.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example9 - Pay-Per-Page Access (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p5
* @live_demo https://gourl.io/lib/examples/pay-per-page.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-post-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example6 - Pay-Per-Post (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p3
* @live_demo https://gourl.io/lib/examples/pay-per-post-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-post.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example5 - Pay-Per-Post (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p3
* @live_demo https://gourl.io/lib/examples/pay-per-post.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-product-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example2 - Pay-Per-Product (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p1
* @live_demo https://gourl.io/lib/examples/pay-per-product-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-product.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example1 - Pay-Per-Product (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p1
* @live_demo https://gourl.io/lib/examples/pay-per-product.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-registration-multi.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example8 - Pay-Per-Registration (payments in multiple cryptocurrencies, you can use original price in USD)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p4
* @live_demo https://gourl.io/lib/examples/pay-per-registration-multi.php
Expand Down
2 changes: 1 addition & 1 deletion Examples/pay-per-registration.php
Expand Up @@ -2,7 +2,7 @@
/**
* @category Example7 - Pay-Per-Registration (single crypto currency in payment box)
* @package GoUrl Cryptocurrency Payment API
* copyright (c) 2014-2015 Delta Consultants
* copyright (c) 2014-2016 Delta Consultants
* @crypto Supported Cryptocoins - Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit
* @website https://gourl.io/bitcoin-payment-gateway-api.html#p4
* @live_demo https://gourl.io/lib/examples/pay-per-registration.php
Expand Down
10 changes: 10 additions & 0 deletions Screenshots/index.html
@@ -0,0 +1,10 @@
<html>
<head>
<title>403 Forbidden</title>
</head>
<body>

<p>Directory access is forbidden.</p>

</body>
</html>
4 changes: 2 additions & 2 deletions cryptobox.callback.php
Expand Up @@ -4,10 +4,10 @@
* Cryptobox Server Callbacks
*
* @package Cryptobox callbacks
* @copyright 2014-2015 Delta Consultants
* @copyright 2014-2016 Delta Consultants
* @category Libraries
* @website https://gourl.io
* @version 1.7.3
* @version 1.7.4
*
*
* This file processes call-backs from Cryptocoin Payment Box server when new payment
Expand Down
15 changes: 7 additions & 8 deletions cryptobox.class.php
@@ -1,17 +1,17 @@
<?php
/**
*
* PHP Cryptocurrency Payment Class
* PHP Cryptocurrency Payment Class
*
* @package GoUrl PHP Bitcoin/Altcoin Payments and Crypto Captcha
* @copyright 2014-2015 Delta Consultants
* @copyright 2014-2016 Delta Consultants
* @category Libraries
* @website https://gourl.io
* @api https://gourl.io/api-php.html
* @example https://gourl.io/bitcoin-payment-gateway-api.html
* @gitHub https://github.com/cryptoapi/Payment-Gateway
* @license Free GPLv2
* @version 1.7.3
* @version 1.7.4
*
*
*
Expand Down Expand Up @@ -58,7 +58,7 @@
elseif (!defined('ABSPATH')) exit; // Wordpress


define("CRYPTOBOX_VERSION", "1.7.3");
define("CRYPTOBOX_VERSION", "1.7.4");

// GoUrl supported crypto currencies
define("CRYPTOBOX_COINS", json_encode(array('bitcoin', 'litecoin', 'paycoin', 'dogecoin', 'dash', 'speedcoin', 'reddcoin', 'potcoin', 'feathercoin', 'vertcoin', 'vericoin', 'peercoin', 'monetaryunit')));
Expand Down Expand Up @@ -594,7 +594,7 @@ public function iframe_id()
*/
private function check_payment($remotedb = false)
{
$this->paymentID = $diff = $diff2 = 0;
$this->paymentID = $diff = 0;

$obj = run_sql("SELECT paymentID, amount, amountUSD, txConfirmed, txCheckDate, txDate, processed, boxType FROM crypto_payments WHERE boxID = $this->boxID && orderID = '$this->orderID' && userID = '$this->userID' ".($this->period=="NOEXPIRY"?"":"&& txDate >= DATE_SUB('".gmdate("Y-m-d H:i:s")."', INTERVAL ".$this->period.")")." ORDER BY txDate DESC LIMIT 1");

Expand All @@ -609,12 +609,11 @@ private function check_payment($remotedb = false)
$this->boxType = $obj->boxType;
$this->processed = ($obj->processed) ? true : false;
$diff = strtotime(gmdate('Y-m-d H:i:s')) - strtotime($obj->txCheckDate);
$diff2 = strtotime($obj->txCheckDate) - strtotime($obj->txDate);
}

if (!$obj && isset($_POST["cryptobox_live_"]) && $_POST["cryptobox_live_"] == md5($this->iframeID.$this->private_key.$this->userID)) $remotedb = true;

if ((!$obj && $remotedb) || ($obj && !$this->confirmed && $diff > ($this->coinLabel=='BTC'?35:12)*60 && $diff2 < 44*60*60))
if ((!$obj && $remotedb) || ($obj && !$this->confirmed && ($diff > (($this->coinLabel=='BTC'?35:12)*60) || $diff < 0))) // if $diff < 0 - user have incorrect time on local computer
{
$this->check_payment_live();
}
Expand Down Expand Up @@ -1259,6 +1258,6 @@ function run_sql($sql)
foreach ($cryptobox_private_keys as $v)
if (strpos($v, " ") !== false || strpos($v, "PRV") === false || strpos($v, "AA") === false || strpos($v, "77") === false) die("Invalid Private Key - ". (CRYPTOBOX_WORDPRESS ? "please setup it on your plugin settings page" : "$v in variable \$cryptobox_private_keys, file cryptobox.config.php."));

unset($v); unset($cryptobox_private_keys);
unset($v); unset($cryptobox_private_keys);
}
?>
4 changes: 2 additions & 2 deletions cryptobox.js
Expand Up @@ -3,11 +3,11 @@
* Cryptocoin Payment Box Javascript
*
* @package GoUrl Bitcoin/Altcoin Payment Box and Crypto Captcha
* @copyright 2014-2015 Delta Consultants
* @copyright 2014-2016 Delta Consultants
* @category Javascript
* @website https://gourl.io
* @api https://gourl.io/api.html
* @version 1.7.3
* @version 1.7.4
*
*/

Expand Down
4 changes: 2 additions & 2 deletions cryptobox.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions readme.md
Expand Up @@ -2,7 +2,7 @@
GoUrl.io Cryptocoin Payment Gateway API
-----------------------------------------

Version 1.7.3
Version 1.7.4

**Accept Bitcoin, Litecoin, Paycoin, Dogecoin, Dash, Speedcoin, Reddcoin, Potcoin, Feathercoin, Vertcoin, Vericoin, Peercoin, MonetaryUnit Payments Online on your website**

Expand Down Expand Up @@ -35,7 +35,7 @@ Our Payment Gateway with Instant Checkout allows you to easily organise your web
Information
------------------------------------

Copyright &copy; 2014-2015 [Delta Consultants](https://gourl.io)
Copyright &copy; 2014-2016 [Delta Consultants](https://gourl.io)

Website: [https://gourl.io](https://gourl.io)

Expand Down

0 comments on commit 57754a5

Please sign in to comment.