Products     Magento Extension     PCI-Shopping-Carts     Templates       CRELoaded     WordPress Modules     osCommerce Modules       osCommerce Addons       osCommerce Features       osCommerce Management       Payment Modules     CRELoaded Modules       CRE Loaded Addons       CRE Loaded Features       CRE Loaded Management       Payment Modules       CRELoaded Services
Free Stuff
Customization
Templates
Compare Products
You have no items to compare.
Affiliate Info
Affiliate Program FAQ
Affiliate Log In
Recent Orders
Hot Keywords: Order Notification, Order Search, Coupon, Flash Board, Compare, Floating Message, Tracking, Moneris, RSS, Visitor Filter

  Credit Class & Gift Voucher

The following osCommerce contribution is a free Opensource code originated from official osCommerce website and provided for your reference only, you may download the original contribution file(s) and install it on your own; or you may request a Paid Installation Service from Agents Of Power; Agents Of Power does the "AS IS" installation on your website, we do not guarantee it will work properly on your website. Extra Paid service is available for repairing the problem from the original contribution or from your website.
catalog/checkout_process.php

@line 73
find:

if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {
tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
}

replace with:

if ( ( is_array($payment_modules->modules) && (sizeof($payment_modules->modules) > 1) && !is_object($$payment) && (!$credit_covers) ) || (is_object($$payment) && ($$payment->enabled == false)) ) {
tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(ERROR_NO_PAYMENT_MODULE_SELECTED), 'SSL'));
}

2 days of work to undestand it!
Enjoy!

fix payment problem!
*Sorry. Forgot some files in last upload. This is the full package.

When installing on a fresh install of RC2a, the following errors occur in admin section:

errors on admin/coupon_admin.php
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /gearupaz/public_html/admin/includes/functions/database.php on line 107

errors on admin/gv_mail.php:
Warning: mysql_insert_id(): supplied argument is not a valid MySQL-Link resource in /gearupaz/public_html/admin/includes/functions/database.php on line 117

Warning: Cannot modify header information - headers already sent by (output started at /gearupaz/public_html/admin/includes/functions/database.php:117) in /gearupaz/public_html/admin/includes/functions/general.php on line 22

This is a fix for the CCGV (Contibution 282) where certain database.php errors and other problems are happening with the admin side.

This is a full package for new installation, where the previous package caused some problems for new (drop-in) installations.

*Built onto version 5.21
*Credit for these solutions goes to original contributors and forum users.

Fix gv_mail.php error:
On line 64 replace:
$insert_id = tep_db_insert_id($insert_query);
with:
$insert_id = tep_db_insert_id();

Fix coupon_admin.php (under case: voucherreport, lines:227-230)
replace:
$cc_query_raw = "select * from " . TABLE_COUPON_REDEEM_TRACK . " where coupon_id = '" . (int)$coupon_id . "'";
$cc_query_numrows = tep_db_num_rows($cc_query);
$cc_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $cc_query_raw, $cc_query_numrows);
$cc_query = tep_db_query($cc_query_raw);
with:
$cc_query_raw = "select * from " . TABLE_COUPON_REDEEM_TRACK . " where coupon_id = '" . (int)$coupon_id . "'";
$cc_query = tep_db_query($cc_query_raw);
$cc_query_numrows = tep_db_num_rows($cc_query);
$cc_split = new splitPageResults($HTTP_GET_VARS['page'], MAX_DISPLAY_SEARCH_RESULTS, $cc_query_raw, $cc_query_numrows);

*Thanks OSC community for all efforts and making one of the most practical contributions a possibility.
Upgrading from 5.19 to 5.21 broke several of my payment methods. The
problem happens in includes/classes/payment.php. To fix it, find the
OLD line and replace it with the NEW line.


OLD:
if (defined('MODULE_PAYMENT_INSTALLED') && tep_not_null(MODULE_PAYMENT_INSTALLED) && !$module == 'credit_covers') {


NEW:
if (defined('MODULE_PAYMENT_INSTALLED') && tep_not_null(MODULE_PAYMENT_INSTALLED) && $module != 'credit_covers') {
1) Remove illogical condition.

file: catalog/checkout_payment.php

line: if (MODULE_ORDER_TOTAL_INSTALLED)

action: remove this line

2) Add missing constant.

file: catalog/includes/languages/add_ccgvdc_english.php

line: define('ERROR_NO_ACCOUNT_GV', 'You must sign in to your account to
redeem a Gift Certificate');

action: add this line
When changing the coupon status from Active to Inactive the Dropdown Status form field auto sets to Active Coupons.
This makes the Inactive Coupons invisible. If you want to see the Red Active and the Green Inactive status when changing statused then simlpy follow the these instructions:
Enjoy

in catalog/admin/coupon_admin.php

find:

if ($HTTP_GET_VARS['status']) {
$status = tep_db_prepare_input($HTTP_GET_VARS['status']);
} else {
$status = 'Y';
}

Replase with:

if ($HTTP_GET_VARS['status']) {
$status = tep_db_prepare_input($HTTP_GET_VARS['status']);
} else {
$status = '*';
}
The fix did not show correctly in the description in my last submission - it is in the downloaded file
In checkout_payment.php, if your tables become lop-sided here is the fault.

search for directly below the <!-- body_text //-->:

<?php
// Start - CREDIT CLASS Gift Voucher Contribution
// <td width="100%" valign="top"><?php echo tep_draw_form('checkout_payment', tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, '', 'SSL'), 'post', 'onsubmit="return check_form();"'); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">
<td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
<?php /* End - CREDIT CLASS Gift Voucher Contribution */ ?>

replace with:

<?php
// Start - CREDIT CLASS Gift Voucher Contribution
// <td width="100%" valign="top"><?php echo tep_draw_form('checkout_payment', tep_href_link(FILENAME_CHECKOUT_CONFIRMATION, '', 'SSL'), 'post', 'onsubmit="return check_form();"'); ?>
<td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
<?php /* End - CREDIT CLASS Gift Voucher Contribution */ ?>


no file attached, it is simply a table in the wrong spot
patch of the difference between 5.20_1 and 5.20_2 included in package

Full package
Credit Class and Gift Voucher/Coupon V5.20 contribution for osCommerce RC2/RC2a

Includes all fixes up to June 18 2008.


Fixed a typo error. only one file changed - but this is a FULL package

Feel free to give feed back!

The NEW Paypal has NOT been tested (paypal_standard.php - only). Other older versions have been depreciated - grab and old file if you still want it.

Feel free to give feed back!
Credit Class and Gift Voucher/Coupon V5.20 contribution for osCommerce RC2/RC2a

Includes all fixes up to June 18 2008.

Cleaned up files - coded and formatted to OSC standards - properly marked all changes with the same type of comment.

The NEW Paypal has NOT been tested (paypal_standard.php - only). Other older versions have been depreciated - grab and old file if you still want it.

Feel free to give feed back!
   Posted on: 10/13/2008     See contribution details Request Installation with Paid service