1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 01:39:24 +02:00

Compare commits

...

8 commits

Author SHA1 Message Date
Daniel Neto
d273322ac4 Merge branch 'master' of https://github.com/WWBN/AVideo 2025-09-08 09:12:44 -03:00
Daniel Neto
ba42c8bcf6 Add plans_id parameter to getAvailableRecurrentPayments and related methods 2025-09-08 09:12:42 -03:00
Daniel Neto
f249066af1
Merge pull request #10182 from WWBN/dependabot/npm_and_yarn/fortawesome/fontawesome-free-7.0.1
Bump @fortawesome/fontawesome-free from 7.0.0 to 7.0.1
2025-09-08 06:10:57 -03:00
dependabot[bot]
2ab51634ac
Bump @fortawesome/fontawesome-free from 7.0.0 to 7.0.1
Bumps [@fortawesome/fontawesome-free](https://github.com/FortAwesome/Font-Awesome) from 7.0.0 to 7.0.1.
- [Release notes](https://github.com/FortAwesome/Font-Awesome/releases)
- [Changelog](https://github.com/FortAwesome/Font-Awesome/blob/7.x/CHANGELOG.md)
- [Commits](https://github.com/FortAwesome/Font-Awesome/compare/7.0.0...7.0.1)

---
updated-dependencies:
- dependency-name: "@fortawesome/fontawesome-free"
  dependency-version: 7.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-08 09:08:56 +00:00
Daniel Neto
f60e3e0016
Merge pull request #10181 from WWBN/dependabot/npm_and_yarn/hls.js-1.6.11
Bump hls.js from 1.6.10 to 1.6.11
2025-09-08 06:07:47 -03:00
Daniel Neto
42cfc190c7
Merge pull request #10180 from WWBN/dependabot/npm_and_yarn/bootstrap-5.3.8
Bump bootstrap from 5.3.7 to 5.3.8
2025-09-08 06:07:16 -03:00
dependabot[bot]
fca33618cd
Bump hls.js from 1.6.10 to 1.6.11
Bumps [hls.js](https://github.com/video-dev/hls.js) from 1.6.10 to 1.6.11.
- [Release notes](https://github.com/video-dev/hls.js/releases)
- [Changelog](https://github.com/video-dev/hls.js/blob/master/docs/release-process.md)
- [Commits](https://github.com/video-dev/hls.js/compare/v1.6.10...v1.6.11)

---
updated-dependencies:
- dependency-name: hls.js
  dependency-version: 1.6.11
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-08 09:07:04 +00:00
dependabot[bot]
62e43c4235
Bump bootstrap from 5.3.7 to 5.3.8
Bumps [bootstrap](https://github.com/twbs/bootstrap) from 5.3.7 to 5.3.8.
- [Release notes](https://github.com/twbs/bootstrap/releases)
- [Commits](https://github.com/twbs/bootstrap/compare/v5.3.7...v5.3.8)

---
updated-dependencies:
- dependency-name: bootstrap
  dependency-version: 5.3.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-08 09:07:01 +00:00
12 changed files with 218 additions and 219 deletions

24
package-lock.json generated
View file

@ -5,7 +5,7 @@
"packages": {
"": {
"dependencies": {
"@fortawesome/fontawesome-free": "^7.0.0",
"@fortawesome/fontawesome-free": "^7.0.1",
"@fullcalendar/core": "^6.1.19",
"@fullcalendar/daygrid": "^6.1.18",
"@fullcalendar/interaction": "^6.1.19",
@ -16,7 +16,7 @@
"@silvermine/videojs-chromecast": "^1.5.0",
"animate.css": "^4.1.1",
"blockadblock": "^3.2.1",
"bootstrap": "^5.3.7",
"bootstrap": "^5.3.8",
"bootstrap-fileinput": "^5.5.4",
"chart.js": "^4.5.0",
"chartjs-adapter-date-fns": "^3.0.0",
@ -33,7 +33,7 @@
"font-awesome": "^4.7.0",
"fontawesome-free": "^1.0.4",
"glightbox": "^3.3.1",
"hls.js": "^1.6.10",
"hls.js": "^1.6.11",
"infinite-scroll": "^5.0.0",
"inputmask": "^5.0.9",
"intro.js": "^8.3.2",
@ -157,9 +157,9 @@
}
},
"node_modules/@fortawesome/fontawesome-free": {
"version": "7.0.0",
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-free/-/fontawesome-free-7.0.0.tgz",
"integrity": "sha512-X48nISrSOa89zu2VMljC4XaRf8NmgTwQBVHfS2Nu5G00ZwM31oOVrAtGxZF3b6wDYf9lJsf/Eq4cCSFKIkOWPQ==",
"version": "7.0.1",
"resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-free/-/fontawesome-free-7.0.1.tgz",
"integrity": "sha512-RLmb9U6H2rJDnGxEqXxzy7ANPrQz7WK2/eTjdZqyU9uRU5W+FkAec9uU5gTYzFBH7aoXIw2WTJSCJR4KPlReQw==",
"license": "(CC-BY-4.0 AND OFL-1.1 AND MIT)",
"engines": {
"node": ">=6"
@ -451,9 +451,9 @@
"integrity": "sha512-EDHDL+61Jxjmx661b++9PG6HIE8j8fWXOik5oZ01gPsmuQN+n2WtLJg9IX0UT8f5dQVvF1vM7QhJ8wATffn83Q=="
},
"node_modules/bootstrap": {
"version": "5.3.7",
"resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-5.3.7.tgz",
"integrity": "sha512-7KgiD8UHjfcPBHEpDNg+zGz8L3LqR3GVwqZiBRFX04a1BCArZOz1r2kjly2HQ0WokqTO0v1nF+QAt8dsW4lKlw==",
"version": "5.3.8",
"resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-5.3.8.tgz",
"integrity": "sha512-HP1SZDqaLDPwsNiqRqi5NcP0SSXciX2s9E+RyqJIIqGo+vJeN5AJVM98CXmW/Wux0nQ5L7jeWUdplCEf0Ee+tg==",
"funding": [
{
"type": "github",
@ -824,9 +824,9 @@
}
},
"node_modules/hls.js": {
"version": "1.6.10",
"resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.6.10.tgz",
"integrity": "sha512-16XHorwFNh+hYazYxDNXBLEm5aRoU+oxMX6qVnkbGH3hJil4xLav3/M6NH92VkD1qSOGKXeSm+5unuawPXK6OQ==",
"version": "1.6.11",
"resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.6.11.tgz",
"integrity": "sha512-tdDwOAgPGXohSiNE4oxGr3CI9Hx9lsGLFe6TULUvRk2TfHS+w1tSAJntrvxsHaxvjtr6BXsDZM7NOqJFhU4mmg==",
"license": "Apache-2.0"
},
"node_modules/ieee754": {

View file

@ -1,6 +1,6 @@
{
"dependencies": {
"@fortawesome/fontawesome-free": "^7.0.0",
"@fortawesome/fontawesome-free": "^7.0.1",
"@fullcalendar/core": "^6.1.19",
"@fullcalendar/daygrid": "^6.1.18",
"@fullcalendar/interaction": "^6.1.19",
@ -11,7 +11,7 @@
"@silvermine/videojs-chromecast": "^1.5.0",
"animate.css": "^4.1.1",
"blockadblock": "^3.2.1",
"bootstrap": "^5.3.7",
"bootstrap": "^5.3.8",
"bootstrap-fileinput": "^5.5.4",
"chart.js": "^4.5.0",
"chartjs-adapter-date-fns": "^3.0.0",
@ -28,7 +28,7 @@
"font-awesome": "^4.7.0",
"fontawesome-free": "^1.0.4",
"glightbox": "^3.3.1",
"hls.js": "^1.6.10",
"hls.js": "^1.6.11",
"infinite-scroll": "^5.0.0",
"inputmask": "^5.0.9",
"intro.js": "^8.3.2",

View file

@ -578,7 +578,7 @@ class YPTWallet extends PluginAbstract
return true;
}
public static function getAvailableRecurrentPayments()
public static function getAvailableRecurrentPayments($plans_id)
{
global $global;
@ -598,7 +598,7 @@ class YPTWallet extends PluginAbstract
$file = $subdir . "{$value}.php";
if (is_dir($subdir) && file_exists($file)) {
require_once $file;
$eval = "\$obj = new {$value}();\$obj->getRecurrentAprovalButton();";
$eval = "\$obj = new {$value}();\$obj->getRecurrentAprovalButton({$plans_id});";
eval($eval);
}
}

View file

@ -1,50 +1,50 @@
<?php
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author daniel
*/
abstract class YPTWalletPlugin {
//put your code here
private $invoiceNumber, $value, $currency;
abstract function getAprovalButton();
abstract function getEmptyDataObject();
function getValue(){
return $this->value;
}
function setValue($value){
$this->value = floatval($value);
}
function getInvoiceNumber() {
return $this->invoiceNumber;
}
function setInvoiceNumber($invoiceNumber) {
$this->invoiceNumber = $invoiceNumber;
}
function getCurrency() {
return $this->currency;
}
function setCurrency($currency) {
$this->currency = $currency;
}
public function getRecurrentAprovalButton() {
}
public function getRecurrentAprovalButtonV2($total = '1.00', $currency = "USD", $frequency = "Month", $interval = 1, $name = '', $json = '', $trialDays = 0) {
}
}
<?php
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author daniel
*/
abstract class YPTWalletPlugin {
//put your code here
private $invoiceNumber, $value, $currency;
abstract function getAprovalButton();
abstract function getEmptyDataObject();
function getValue(){
return $this->value;
}
function setValue($value){
$this->value = floatval($value);
}
function getInvoiceNumber() {
return $this->invoiceNumber;
}
function setInvoiceNumber($invoiceNumber) {
$this->invoiceNumber = $invoiceNumber;
}
function getCurrency() {
return $this->currency;
}
function setCurrency($currency) {
$this->currency = $currency;
}
public function getRecurrentAprovalButton($plans_id) {
}
public function getRecurrentAprovalButtonV2($total = '1.00', $currency = "USD", $frequency = "Month", $interval = 1, $name = '', $json = '', $trialDays = 0) {
}
}

View file

@ -27,7 +27,7 @@ $_page = new Page(array('Payment tests'));
</div>
<div class="panel-body">
<?php
$myWallet->getAvailableRecurrentPayments();
$myWallet->getAvailableRecurrentPayments($_GET['plans_id']);
?>
</div>
</div>
@ -166,4 +166,4 @@ $_page = new Page(array('Payment tests'));
</div>
<?php
$_page->print();
?>
?>

View file

@ -16,7 +16,7 @@ class YPTWalletAuthorizeNet extends YPTWalletPlugin {
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletAuthorizeNet/confirmButton.php';
}
public function getRecurrentAprovalButton() {
public function getRecurrentAprovalButton($plans_id) {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletAuthorizeNet/confirmButton.php';
}

View file

@ -2,7 +2,7 @@
$obj = AVideoPlugin::getObjectData("AuthorizeNet");
?>
<div class="btn-group" role="group" aria-label="Authorize.Net Actions">
<button class="btn btn-primary" onclick="startAuthorizeNetAcceptHosted()">
<button class="btn btn-primary" onclick="startAuthorizeNetAcceptHosted(<?php echo intval(empty($plans_id) ? @$_GET['plans_id'] : $plans_id); ?>)">
<i class="fas fa-credit-card"></i>
<?php
if (!empty($_REQUEST['plans_id'])) {
@ -18,9 +18,8 @@ $obj = AVideoPlugin::getObjectData("AuthorizeNet");
</div>
<script>
function startAuthorizeNetAcceptHosted() {
const amount = $('#value<?php echo @$_GET['plans_id']; ?>').val();
const plans_id = <?php echo intval(@$_GET['plans_id']); ?>;
function startAuthorizeNetAcceptHosted(plans_id) {
const amount = $('#value' + plans_id).val();
if (!amount || isNaN(amount) || amount <= 0) {
if (plans_id <= 0) {
avideoAlertError('Invalid data');

View file

@ -11,7 +11,7 @@ class YPTWalletBTC extends YPTWalletPlugin{
}
public function getRecurrentAprovalButton() {
public function getRecurrentAprovalButton($plans_id) {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletBTC/confirmRecurrentButton.php';
}

View file

@ -1,40 +1,40 @@
<?php
/**
-2 : PAYMENT_EXPIRED
-1 : PAYMENT_ERROR (Happens when Paid BTC amount is not matching expected value)
0 : UNPAID
1 : IN_PROCESS
2 : PAID
*/
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletBlockonomics extends YPTWalletPlugin{
public function getAprovalLink() {
global $global;
$plugin = AVideoPlugin::loadPluginIfEnabled("PayPalYPT");
$payment = $plugin->setUpPayment(
$this->getInvoiceNumber(),
$this->getRedirectURL(),
$this->getCancelURL(),
$this->getValue(),
$this->getCurrency());
if (!empty($payment)) {
return $payment->getApprovalLink();
}
return false;
}
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletBlockonomics/confirmButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
return $obj;
}
}
<?php
/**
-2 : PAYMENT_EXPIRED
-1 : PAYMENT_ERROR (Happens when Paid BTC amount is not matching expected value)
0 : UNPAID
1 : IN_PROCESS
2 : PAID
*/
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletBlockonomics extends YPTWalletPlugin{
public function getAprovalLink() {
global $global;
$plugin = AVideoPlugin::loadPluginIfEnabled("PayPalYPT");
$payment = $plugin->setUpPayment(
$this->getInvoiceNumber(),
'',
'',
$this->getValue(),
$this->getCurrency());
if (!empty($payment)) {
return $payment->getApprovalLink();
}
return false;
}
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletBlockonomics/confirmButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
return $obj;
}
}

View file

@ -1,53 +1,53 @@
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletPayPal extends YPTWalletPlugin{
public function getAprovalLink() {
global $global;
$plugin = AVideoPlugin::loadPluginIfEnabled("PayPalYPT");
$payment = $plugin->setUpPayment(
$this->getInvoiceNumber(),
$this->getRedirectURL(),
$this->getCancelURL(),
$this->getValue(),
$this->getCurrency());
if (!empty($payment)) {
return $payment->getApprovalLink();
}
return false;
}
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmButton.php';
}
public function getRecurrentAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmRecurrentButton.php';
}
public function getRecurrentAprovalButtonV2($total = '1.00', $currency = "USD", $frequency = "Month", $interval = 1, $name = '', $json = '', $addFunds_Success='', $trialDays = 0) {
$total = floatval($total);
if(empty($total)){
return '';
}
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmRecurrentButtonV2.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
//$obj->RedirectURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletPayPal/redirect_url.php";
//$obj->CancelURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletPayPal/cancel_url.php";
return $obj;
}
}
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletPayPal extends YPTWalletPlugin{
public function getAprovalLink() {
global $global;
$plugin = AVideoPlugin::loadPluginIfEnabled("PayPalYPT");
$payment = $plugin->setUpPayment(
$this->getInvoiceNumber(),
'',
'',
$this->getValue(),
$this->getCurrency());
if (!empty($payment)) {
return $payment->getApprovalLink();
}
return false;
}
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmButton.php';
}
public function getRecurrentAprovalButton($plans_id) {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmRecurrentButton.php';
}
public function getRecurrentAprovalButtonV2($total = '1.00', $currency = "USD", $frequency = "Month", $interval = 1, $name = '', $json = '', $addFunds_Success='', $trialDays = 0) {
$total = floatval($total);
if(empty($total)){
return '';
}
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletPayPal/confirmRecurrentButtonV2.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
//$obj->RedirectURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletPayPal/redirect_url.php";
//$obj->CancelURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletPayPal/cancel_url.php";
return $obj;
}
}

View file

@ -1,24 +1,24 @@
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletRazorPay extends YPTWalletPlugin{
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletRazorPay/confirmButton.php';
}
public function getRecurrentAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletRazorPay/confirmRecurrentButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
return $obj;
}
}
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletRazorPay extends YPTWalletPlugin{
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletRazorPay/confirmButton.php';
}
public function getRecurrentAprovalButton($plans_id) {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletRazorPay/confirmRecurrentButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
return $obj;
}
}

View file

@ -1,27 +1,27 @@
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletStripe extends YPTWalletPlugin{
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletStripe/confirmButton.php';
}
public function getRecurrentAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletStripe/confirmRecurrentButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
//$obj->RedirectURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletStripe/redirect_url.php";
//$obj->CancelURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletStripe/cancel_url.php";
return $obj;
}
}
<?php
global $global;
require_once $global['systemRootPath'] . 'plugin/YPTWallet/YPTWalletPlugin.php';
class YPTWalletStripe extends YPTWalletPlugin{
public function getAprovalButton() {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletStripe/confirmButton.php';
}
public function getRecurrentAprovalButton($plans_id) {
global $global;
include $global['systemRootPath'].'plugin/YPTWallet/plugins/YPTWalletStripe/confirmRecurrentButton.php';
}
public function getEmptyDataObject() {
global $global;
$obj = new stdClass();
//$obj->RedirectURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletStripe/redirect_url.php";
//$obj->CancelURL = "{$global['webSiteRootURL']}plugin/YPTWallet/plugins/YPTWalletStripe/cancel_url.php";
return $obj;
}
}