Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • awit-whmcs/whmcs-coza-epp
  • weheartwebsites/whmcs-coza-epp
  • qbitza/whmcs-coza-epp
  • wyrie/whmcs-coza-epp
  • Woklet/whmcs-coza-epp
  • jaymcc/whmcs-coza-epp
  • cmcawood/whmcs-coza-epp
7 results
Show changes
Commits on Source (3)
Showing
with 29 additions and 29 deletions
......@@ -36,8 +36,8 @@
* integration, customizations and consulting all available from
* http://allworldit.com
* Buzybuy - cozaepp Disable Auto Renew
* This script is a modification of the original cozaeppsync.php script from AllWorldIT combined with code from
* Buzybuy - zacr Disable Auto Renew
* This script is a modification of the original zacrsync.php script from AllWorldIT combined with code from
* Everything Web CC script.
* This script will loop through all the coza domains in your WHMCS database.
* Each domain's auto renew will be set to false on the domain.
......@@ -48,24 +48,24 @@
// This file brings in a few constants we need
require_once dirname(__FILE__) . '/../../../dbconnect.php';
// Setup include dir
$include_path = ROOTDIR . '/modules/registrars/cozaepp';
$include_path = ROOTDIR . '/modules/registrars/zacr';
set_include_path($include_path . PATH_SEPARATOR . get_include_path());
// Include EPP stuff we need
require_once 'cozaepp.php';
require_once 'zacr.php';
// Additional functions we need
require_once ROOTDIR . '/includes/functions.php';
// Include registrar functions aswell
require_once ROOTDIR . '/includes/registrarfunctions.php';
// Grab module parameters
$params = getregistrarconfigoptions('cozaepp');
$params = getregistrarconfigoptions('zacr');
echo("COZA-EPP Domain Set Auto Renew To False Report\n");
echo("ZACR Domain Set Auto Renew To False Report\n");
echo("---------------------------------------------------\n");
// Request balance from registrar
try {
$client = _cozaepp_Client();
$client = _zacr_Client();
// Pull list of domains which are registered using this module
$queryresult = mysql_query("
......@@ -73,7 +73,7 @@ try {
domain
FROM
tbldomains
WHERE registrar = 'cozaepp'"
WHERE registrar = 'zacr'"
);
while($data = mysql_fetch_array($queryresult)) {
$domains[] = trim(strtolower($data['domain']));
......@@ -149,7 +149,7 @@ foreach ($domains as $domain) {
}
}
} else {
echo "Domain renew status update on $domain not successful: "._cozaepp_message($coderes)."\n";
echo "Domain renew status update on $domain not successful: "._zacr_message($coderes)."\n";
continue;
}
} else {
......@@ -157,7 +157,7 @@ foreach ($domains as $domain) {
continue;
}
} else {
echo "Domain info on $domain not successful: "._cozaepp_message($coderes)."\n";
echo "Domain info on $domain not successful: "._zacr_message($coderes)."\n";
continue;
}
......
<?php
/**
* AWIT COZAEPP - COZA EPP Module
* AWIT ZACR - COZA EPP Module
* Copyright (c) 2014, AllWorldIT
*
* This program is free software: you can redistribute it and/or modify
......@@ -23,17 +23,17 @@ if (!defined("WHMCS"))
die("This file cannot be accessed directly");
// Our global supported field list
$AWIT_COZAEPP_SUPPORTED_FIELDS = array(
$AWIT_ZACR_SUPPORTED_FIELDS = array(
"max_items"
);
// Addon configuration
function awit_cozaepp_config()
function awit_zacr_config()
{
// Configuration
$configarray = array(
"name" => "AWIT COZAEPP",
"name" => "AWIT ZACR",
"description" => "This module is to facilitate displaying of epp messages.",
"version" => "0.1",
"author" => "AllWorldIT",
......@@ -54,21 +54,21 @@ function awit_cozaepp_config()
function awit_cozaepp_get_config_custom_fields()
function awit_zacr_get_config_custom_fields()
{
global $AWIT_COZAEPP_SUPPORTED_FIELDS;
global $AWIT_ZACR_SUPPORTED_FIELDS;
// Query modules table
$table = "tbladdonmodules";
$fields = "setting,value";
$where = array( 'module' => 'awit_cozaepp' );
$where = array( 'module' => 'awit_zacr' );
$result = select_query($table,$fields,$where);
// Filter out the settings we need
$custom_fields = array();
while ($row = mysql_fetch_array($result)) {
// Check in our global list
if (in_array($row['setting'],$AWIT_COZAEPP_SUPPORTED_FIELDS)) {
if (in_array($row['setting'],$AWIT_ZACR_SUPPORTED_FIELDS)) {
$custom_fields[$row['setting']] = $row['value'];
}
}
......@@ -78,21 +78,21 @@ function awit_cozaepp_get_config_custom_fields()
function _awit_cozaepp_getMaxItems()
function _awit_zacr_getMaxItems()
{
$customFields = awit_cozaepp_get_config_custom_fields();
$customFields = awit_zacr_get_config_custom_fields();
return $customFields['max_items'];
}
// Addon activation
function awit_cozaepp_activate()
function awit_zacr_activate()
{
// Create Custom DB Table
$result = mysql_query("
CREATE TABLE `mod_awit_cozaepp_messages` (
CREATE TABLE `mod_awit_zacr_messages` (
`id` INT( 1 ) NOT NULL AUTO_INCREMENT PRIMARY KEY,
`created` DATETIME NOT NULL,
`code` VARCHAR(10) NOT NULL,
......@@ -111,11 +111,11 @@ function awit_cozaepp_activate()
function awit_cozaepp_deactivate()
function awit_zacr_deactivate()
{
// Remove custom tables
$result1 = mysql_query("
DROP TABLE `mod_awit_cozaepp_messages`
DROP TABLE `mod_awit_zacr_messages`
");
if (!$result) {
......@@ -129,7 +129,7 @@ function awit_cozaepp_deactivate()
// Addon output
function awit_cozaepp_output($vars)
function awit_zacr_output($vars)
{
// Check if we have to display all records
if (isset($_POST['button']) && $_POST['button'] == 'Display All') {
......@@ -189,7 +189,7 @@ function awit_cozaepp_output($vars)
$orderClause = 'ORDER BY created DESC';
// Max amount of records to show per page
$recordMax = _awit_cozaepp_getMaxItems();
$recordMax = _awit_zacr_getMaxItems();
// Validation
if (!is_numeric($recordMax)) {
......@@ -226,7 +226,7 @@ function awit_cozaepp_output($vars)
SELECT
COUNT(*) AS cnt
FROM
mod_awit_cozaepp_messages
mod_awit_zacr_messages
%s %s
",
$whereClause,
......@@ -242,7 +242,7 @@ function awit_cozaepp_output($vars)
SELECT
*
FROM
mod_awit_cozaepp_messages
mod_awit_zacr_messages
%s %s %s
",
$whereClause,
......
<?php
$_ADDONLANG['intro'] = "AWIT COZAEPP Module";
$_ADDONLANG['intro'] = "AWIT ZACR Module";
$_ADDONLANG['description'] = "This module is to facilitate displaying of epp messages.";
$_ADDONLANG['documentation'] = "Pending..";
......