Jump to content



Photo
* * * * * 5 votes

[Contribution] Discount Coupon Codes


  • Please log in to reply
3390 replies to this topic

#61   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 03:29

Is there an entry in includes/filenames.php that says:

define( 'FILENAME_UPCOMING_PRODUCTS', 'upcoming_products.php' );
We did at one point. Hang in there.


This is everything I've got:

// define the filenames used in the project
define('FILENAME_BACKUP', 'backup.php');
define('FILENAME_BANNER_MANAGER', 'banner_manager.php');
define('FILENAME_BANNER_STATISTICS', 'banner_statistics.php');
define('FILENAME_CACHE', 'cache.php');
define('FILENAME_CATALOG_ACCOUNT_HISTORY_INFO', 'account_history_info.php');
define('FILENAME_CATEGORIES', 'categories.php');
define('FILENAME_CONFIGURATION', 'configuration.php');
define('FILENAME_COUNTRIES', 'countries.php');
define('FILENAME_CURRENCIES', 'currencies.php');
define('FILENAME_CUSTOMERS', 'customers.php');
define('FILENAME_DEFAULT', 'index.php');
define('FILENAME_DEFINE_LANGUAGE', 'define_language.php');
//kgt - discount coupons
define('FILENAME_DISCOUNT_COUPONS','coupons.php');
//end kgt - discount coupons
define('FILENAME_FILE_MANAGER', 'file_manager.php');
define('FILENAME_GEO_ZONES', 'geo_zones.php');
define('FILENAME_LANGUAGES', 'languages.php');
define('FILENAME_MAIL', 'mail.php');
define('FILENAME_MANUFACTURERS', 'manufacturers.php');
define('FILENAME_MODULES', 'modules.php');
define('FILENAME_NEWSLETTERS', 'newsletters.php');
define('FILENAME_ORDERS', 'orders.php');
define('FILENAME_ORDERS_INVOICE', 'invoice.php');
define('FILENAME_ORDERS_PACKINGSLIP', 'packingslip.php');
define('FILENAME_ORDERS_STATUS', 'orders_status.php');
define('FILENAME_POPUP_IMAGE', 'popup_image.php');
define('FILENAME_PRODUCTS_ATTRIBUTES', 'products_attributes.php');
define('FILENAME_PRODUCTS_EXPECTED', 'products_expected.php');
define('FILENAME_REVIEWS', 'reviews.php');
define('FILENAME_SERVER_INFO', 'server_info.php');
define('FILENAME_SHIPPING_MODULES', 'shipping_modules.php');
define('FILENAME_SPECIALS', 'specials.php');
define('FILENAME_STATS_CUSTOMERS', 'stats_customers.php');
define('FILENAME_STATS_PRODUCTS_PURCHASED', 'stats_products_purchased.php');
define('FILENAME_STATS_PRODUCTS_VIEWED', 'stats_products_viewed.php');
define('FILENAME_TAX_CLASSES', 'tax_classes.php');
define('FILENAME_TAX_RATES', 'tax_rates.php');
define('FILENAME_WHOS_ONLINE', 'whos_online.php');
define('FILENAME_ZONES', 'zones.php');
?>

I'm trying to hang in there. I have some advice: never use iWeb. It's been a rough couple of days. Our friends lost a horse, and it was awful. And nothing HTML is working. Nothing I touch is working -

#62   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 03:34

Don't know quite what you mean by only one in a given program. There can be (and should be) several files of the same name, but they do not exist in the same directory. For example, the language files (in includes/languages) have the same name as the code files they provide the text for.

The admin section is a different ball game. It may be in your catalog directory, but it does not have to be. Some people put it in a different place, or name it a different name. That is why the instructions treat it like it's on the same level as the catalog. When you install to the catalog and to the admin, you're almost doing two different installations. There's technically no reason you must install the admin part (you could install the module manually in the database and create coupons directly and they'd still work no problem.)


Okay. I think what happened was that M (my son) copied the Admin file in the download to the main store directory, so there were two of them - one on the same level as catalogue, one inside. It didn't seem to have an effect on the store last night, though. This morning, I found it, and dumped the one he'd experimented with. The problem with young hotdogers is that they try things like they're gonna live forever. Me, I'm not going to mess with stuff until I'm sure.

If it doesn't matter if you install to the Admin, what IS the admin?

#63   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 03:55

This is everything I've got:

// define the filenames used in the project
define('FILENAME_BACKUP', 'backup.php');
define('FILENAME_BANNER_MANAGER', 'banner_manager.php');
define('FILENAME_BANNER_STATISTICS', 'banner_statistics.php');
define('FILENAME_CACHE', 'cache.php');
define('FILENAME_CATALOG_ACCOUNT_HISTORY_INFO', 'account_history_info.php');
define('FILENAME_CATEGORIES', 'categories.php');
define('FILENAME_CONFIGURATION', 'configuration.php');
define('FILENAME_COUNTRIES', 'countries.php');
define('FILENAME_CURRENCIES', 'currencies.php');
define('FILENAME_CUSTOMERS', 'customers.php');
define('FILENAME_DEFAULT', 'index.php');
define('FILENAME_DEFINE_LANGUAGE', 'define_language.php');
//kgt - discount coupons
define('FILENAME_DISCOUNT_COUPONS','coupons.php');
//end kgt - discount coupons
define('FILENAME_FILE_MANAGER', 'file_manager.php');
define('FILENAME_GEO_ZONES', 'geo_zones.php');
define('FILENAME_LANGUAGES', 'languages.php');
define('FILENAME_MAIL', 'mail.php');
define('FILENAME_MANUFACTURERS', 'manufacturers.php');
define('FILENAME_MODULES', 'modules.php');
define('FILENAME_NEWSLETTERS', 'newsletters.php');
define('FILENAME_ORDERS', 'orders.php');
define('FILENAME_ORDERS_INVOICE', 'invoice.php');
define('FILENAME_ORDERS_PACKINGSLIP', 'packingslip.php');
define('FILENAME_ORDERS_STATUS', 'orders_status.php');
define('FILENAME_POPUP_IMAGE', 'popup_image.php');
define('FILENAME_PRODUCTS_ATTRIBUTES', 'products_attributes.php');
define('FILENAME_PRODUCTS_EXPECTED', 'products_expected.php');
define('FILENAME_REVIEWS', 'reviews.php');
define('FILENAME_SERVER_INFO', 'server_info.php');
define('FILENAME_SHIPPING_MODULES', 'shipping_modules.php');
define('FILENAME_SPECIALS', 'specials.php');
define('FILENAME_STATS_CUSTOMERS', 'stats_customers.php');
define('FILENAME_STATS_PRODUCTS_PURCHASED', 'stats_products_purchased.php');
define('FILENAME_STATS_PRODUCTS_VIEWED', 'stats_products_viewed.php');
define('FILENAME_TAX_CLASSES', 'tax_classes.php');
define('FILENAME_TAX_RATES', 'tax_rates.php');
define('FILENAME_WHOS_ONLINE', 'whos_online.php');
define('FILENAME_ZONES', 'zones.php');
?>

I'm trying to hang in there. I have some advice: never use iWeb. It's been a rough couple of days. Our friends lost a horse, and it was awful. And nothing HTML is working. Nothing I touch is working -


That's admin/includes/filenames.php

includes/filenames.php should look like this:

<?php
/*
  $Id: filenames.php,v 1.4 2003/06/11 17:38:00 hpdl Exp $

  osCommerce, Open Source E-Commerce Solutions
  http://www.oscommerce.com

  Copyright (c) 2003 osCommerce

  Released under the GNU General Public License
*/

// define the filenames used in the project
  define('FILENAME_ACCOUNT', 'account.php');
  define('FILENAME_ACCOUNT_EDIT', 'account_edit.php');
  define('FILENAME_ACCOUNT_HISTORY', 'account_history.php');
  define('FILENAME_ACCOUNT_HISTORY_INFO', 'account_history_info.php');
  define('FILENAME_ACCOUNT_NEWSLETTERS', 'account_newsletters.php');
  define('FILENAME_ACCOUNT_NOTIFICATIONS', 'account_notifications.php');
  define('FILENAME_ACCOUNT_PASSWORD', 'account_password.php');
  define('FILENAME_ADDRESS_BOOK', 'address_book.php');
  define('FILENAME_ADDRESS_BOOK_PROCESS', 'address_book_process.php');
  define('FILENAME_ADVANCED_SEARCH', 'advanced_search.php');
  define('FILENAME_ADVANCED_SEARCH_RESULT', 'advanced_search_result.php');
  define('FILENAME_ALSO_PURCHASED_PRODUCTS', 'also_purchased_products.php');
  define('FILENAME_CHECKOUT_CONFIRMATION', 'checkout_confirmation.php');
  define('FILENAME_CHECKOUT_PAYMENT', 'checkout_payment.php');
  define('FILENAME_CHECKOUT_PAYMENT_ADDRESS', 'checkout_payment_address.php');
  define('FILENAME_CHECKOUT_PROCESS', 'checkout_process.php');
  define('FILENAME_CHECKOUT_SHIPPING', 'checkout_shipping.php');
  define('FILENAME_CHECKOUT_SHIPPING_ADDRESS', 'checkout_shipping_address.php');
  define('FILENAME_CHECKOUT_SUCCESS', 'checkout_success.php');
  define('FILENAME_CONTACT_US', 'contact_us.php');
  define('FILENAME_CONDITIONS', 'conditions.php');
  define('FILENAME_COOKIE_USAGE', 'cookie_usage.php');
  define('FILENAME_CREATE_ACCOUNT', 'create_account.php');
  define('FILENAME_CREATE_ACCOUNT_SUCCESS', 'create_account_success.php');
  define('FILENAME_DEFAULT', 'index.php');
  define('FILENAME_DOWNLOAD', 'download.php');
  define('FILENAME_INFO_SHOPPING_CART', 'info_shopping_cart.php');
  define('FILENAME_LOGIN', 'login.php');
  define('FILENAME_LOGOFF', 'logoff.php');
  define('FILENAME_NEW_PRODUCTS', 'new_products.php');
  define('FILENAME_PASSWORD_FORGOTTEN', 'password_forgotten.php');
  define('FILENAME_POPUP_IMAGE', 'popup_image.php');
  define('FILENAME_POPUP_SEARCH_HELP', 'popup_search_help.php');
  define('FILENAME_PRIVACY', 'privacy.php');
  define('FILENAME_PRODUCT_INFO', 'product_info.php');
  define('FILENAME_PRODUCT_LISTING', 'product_listing.php');
  define('FILENAME_PRODUCT_REVIEWS', 'product_reviews.php');
  define('FILENAME_PRODUCT_REVIEWS_INFO', 'product_reviews_info.php');
  define('FILENAME_PRODUCT_REVIEWS_WRITE', 'product_reviews_write.php');
  define('FILENAME_PRODUCTS_NEW', 'products_new.php');
  define('FILENAME_REDIRECT', 'redirect.php');
  define('FILENAME_REVIEWS', 'reviews.php');
  define('FILENAME_SHIPPING', 'shipping.php');
  define('FILENAME_SHOPPING_CART', 'shopping_cart.php');
  define('FILENAME_SPECIALS', 'specials.php');
  define('FILENAME_SSL_CHECK', 'ssl_check.php');
  define('FILENAME_TELL_A_FRIEND', 'tell_a_friend.php');
  define('FILENAME_UPCOMING_PRODUCTS', 'upcoming_products.php');
?>


#64   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 04:03

Okay. I think what happened was that M (my son) copied the Admin file in the download to the main store directory, so there were two of them - one on the same level as catalogue, one inside. It didn't seem to have an effect on the store last night, though. This morning, I found it, and dumped the one he'd experimented with. The problem with young hotdogers is that they try things like they're gonna live forever. Me, I'm not going to mess with stuff until I'm sure.

If it doesn't matter if you install to the Admin, what IS the admin?


The admin is a web interface to manage the store. The store does not rely on the existence of the admin section though. They're separate entities who access the same database. You wouldn't want to, but you could in theory run an OSC store without any admin section at all. When I say it doesn't matter, I mean it doesn't technically matter. Logically it does matter, because you'd want an administrative tool. /wink.gif' class='bbc_emoticon' alt=';)' /> In that way, they can be considered almost separate applications, since one doesn't strictly rely on the existence of the other in order to work.

If you copy admin files over your store front files, then you will get errors, because you've now got code intended for a different application.

Hope that makes some sense.

#65   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 04:19

That's admin/includes/filenames.php

includes/filenames.php should look like this:

<?php
/*
  $Id: filenames.php,v 1.4 2003/06/11 17:38:00 hpdl Exp $

  osCommerce, Open Source E-Commerce Solutions
  http://www.oscommerce.com

  Copyright (c) 2003 osCommerce

  Released under the GNU General Public License
*/

// define the filenames used in the project
  define('FILENAME_ACCOUNT', 'account.php');
  define('FILENAME_ACCOUNT_EDIT', 'account_edit.php');
  define('FILENAME_ACCOUNT_HISTORY', 'account_history.php');
  define('FILENAME_ACCOUNT_HISTORY_INFO', 'account_history_info.php');
  define('FILENAME_ACCOUNT_NEWSLETTERS', 'account_newsletters.php');
  define('FILENAME_ACCOUNT_NOTIFICATIONS', 'account_notifications.php');
  define('FILENAME_ACCOUNT_PASSWORD', 'account_password.php');
  define('FILENAME_ADDRESS_BOOK', 'address_book.php');
  define('FILENAME_ADDRESS_BOOK_PROCESS', 'address_book_process.php');
  define('FILENAME_ADVANCED_SEARCH', 'advanced_search.php');
  define('FILENAME_ADVANCED_SEARCH_RESULT', 'advanced_search_result.php');
  define('FILENAME_ALSO_PURCHASED_PRODUCTS', 'also_purchased_products.php');
  define('FILENAME_CHECKOUT_CONFIRMATION', 'checkout_confirmation.php');
  define('FILENAME_CHECKOUT_PAYMENT', 'checkout_payment.php');
  define('FILENAME_CHECKOUT_PAYMENT_ADDRESS', 'checkout_payment_address.php');
  define('FILENAME_CHECKOUT_PROCESS', 'checkout_process.php');
  define('FILENAME_CHECKOUT_SHIPPING', 'checkout_shipping.php');
  define('FILENAME_CHECKOUT_SHIPPING_ADDRESS', 'checkout_shipping_address.php');
  define('FILENAME_CHECKOUT_SUCCESS', 'checkout_success.php');
  define('FILENAME_CONTACT_US', 'contact_us.php');
  define('FILENAME_CONDITIONS', 'conditions.php');
  define('FILENAME_COOKIE_USAGE', 'cookie_usage.php');
  define('FILENAME_CREATE_ACCOUNT', 'create_account.php');
  define('FILENAME_CREATE_ACCOUNT_SUCCESS', 'create_account_success.php');
  define('FILENAME_DEFAULT', 'index.php');
  define('FILENAME_DOWNLOAD', 'download.php');
  define('FILENAME_INFO_SHOPPING_CART', 'info_shopping_cart.php');
  define('FILENAME_LOGIN', 'login.php');
  define('FILENAME_LOGOFF', 'logoff.php');
  define('FILENAME_NEW_PRODUCTS', 'new_products.php');
  define('FILENAME_PASSWORD_FORGOTTEN', 'password_forgotten.php');
  define('FILENAME_POPUP_IMAGE', 'popup_image.php');
  define('FILENAME_POPUP_SEARCH_HELP', 'popup_search_help.php');
  define('FILENAME_PRIVACY', 'privacy.php');
  define('FILENAME_PRODUCT_INFO', 'product_info.php');
  define('FILENAME_PRODUCT_LISTING', 'product_listing.php');
  define('FILENAME_PRODUCT_REVIEWS', 'product_reviews.php');
  define('FILENAME_PRODUCT_REVIEWS_INFO', 'product_reviews_info.php');
  define('FILENAME_PRODUCT_REVIEWS_WRITE', 'product_reviews_write.php');
  define('FILENAME_PRODUCTS_NEW', 'products_new.php');
  define('FILENAME_REDIRECT', 'redirect.php');
  define('FILENAME_REVIEWS', 'reviews.php');
  define('FILENAME_SHIPPING', 'shipping.php');
  define('FILENAME_SHOPPING_CART', 'shopping_cart.php');
  define('FILENAME_SPECIALS', 'specials.php');
  define('FILENAME_SSL_CHECK', 'ssl_check.php');
  define('FILENAME_TELL_A_FRIEND', 'tell_a_friend.php');
  define('FILENAME_UPCOMING_PRODUCTS', 'upcoming_products.php');
?>


Okay - catalogue/includes/filenames

looks EXACTLY the same as the admin ones. What I see, though is that your filenames are version 1.4. Mine are 1.1 but with a later date. Obviously, then, I have a problem - I don't have anything like the above list, then.

#66   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 04:22

The admin is a web interface to manage the store. The store does not rely on the existence of the admin section though. They're separate entities who access the same database. You wouldn't want to, but you could in theory run an OSC store without any admin section at all. When I say it doesn't matter, I mean it doesn't technically matter. Logically it does matter, because you'd want an administrative tool. /wink.gif' class='bbc_emoticon' alt=';)' /> In that way, they can be considered almost separate applications, since one doesn't strictly rely on the existence of the other in order to work.

If you copy admin files over your store front files, then you will get errors, because you've now got code intended for a different application.

Hope that makes some sense.


Oh. All right. That's why you want to update both - for interface and for functionality. I think I'm getting it. I just can't figure out how both of my filename lists ended up being the same??

#67   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 04:25

Oh. All right. That's why you want to update both - for interface and for functionality. I think I'm getting it. I just can't figure out how both of my filename lists ended up being the same??



Oh, wait. Yes I do. Obviously, we slipped the new filenames into the catalogue includes instead of into the admin includes. Great. Now what do I do? Would that have been responsible for all of the mess I'm in? I can see that it would.

#68   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 05:04

Oh, wait. Yes I do. Obviously, we slipped the new filenames into the catalogue includes instead of into the admin includes. Great. Now what do I do? Would that have been responsible for all of the mess I'm in? I can see that it would.


Okay. I copied the list you sent me and I overwrote the bad list. MAGIC! Suddenly, I feel a little better, like I might not be brain dead after all. But, all I fixed was the presentation in the middle section of the graphics - which are still at the dead bottom of the page, after the still present column of code. And the side bar graphics and all of the titles are still bad - Header_Title_Top>>Header etc. Box_Heading_Whats_New Stuff like that. So I haven't solved the bulk of the problem.

Any other wisdom?

#69   maz

maz
  • Members
  • 161 posts
  • Real Name:mazhar

Posted 13 June 2006 - 06:59

This is in no way connected to CCGV and does not rely on it.


Excellent. Also, I know the coupons do a % discount. Can I also create coupons with specific values. For example coupon value 1, coupon value 5 , etc.

Edited by maz, 13 June 2006 - 07:01.


#70   DarrenWu

DarrenWu
  • Members
  • 23 posts
  • Real Name:Darren

Posted 13 June 2006 - 07:03

Hi Kgt,

Installed your new update package, it works great. I have an another idea for your Addon.

Right now the Max Use function is per customer. As we know Dell.com they also have Max Use limited on their coupons. But the limitation is set for whole store.

That means you can add one more limited usage per coupon code. The 12345 is the coupon code that allow 1 time per each customer and also "n" times for the whole store customers.

#71   Pilly

Pilly
  • Members
  • 112 posts
  • Real Name:Phil

Posted 13 June 2006 - 08:21

Hi,

Wishlist for me would be also have the choice between % discount and a static figure. And also the ability to match the coupon up against a certain product (model)?

#72   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 13:45

Wishlist for me would be also have the choice between % discount and a static figure. And also the ability to match the coupon up against a certain product (model)?


Hi Philly. A static discount would be nice, but it's unfortunately much more complicated than a percentage discount. This discount happens before tax, so it needs to be applied to all tax groups individually. Due to the way OSC handles tax, this actually means the discount must be applied to each product individually. It's much more complicated to properly handle a discount amount versus a percentage. This is on my list of "things that would be nice" but it requires enough change that I'm not currently working on it.

Someone has suggested to me that the ability to exclude products would be nice, and that's something I'm currently working on.

#73   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 13:46

Excellent. Also, I know the coupons do a % discount. Can I also create coupons with specific values. For example coupon value 1, coupon value 5 , etc.


Currently the discount can only be set to a percentage.

#74   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 13:48

Right now the Max Use function is per customer. As we know Dell.com they also have Max Use limited on their coupons. But the limitation is set for whole store.

That means you can add one more limited usage per coupon code. The 12345 is the coupon code that allow 1 time per each customer and also "n" times for the whole store customers.

Something like "Available Coupons?" That seems like a quickie. If you're really interested, I can throw that together and let you test it out!

#75   philcopain

philcopain
  • Members
  • 2 posts
  • Real Name:Phil

Posted 13 June 2006 - 14:40

Install the latest version which was uploaded today and see if that fixes it.


Hi
This contribution is what i really need but ...

I have manually installed the last version ... everything works fine until the last validation
( I can create a discount coupon, i can valid the cart, the price is exact with the discount, etc ... )
then i get this error message :

" 1146 - Table 'db157787952.TABLE_DISCOUNT_COUPONS_USE_COUNT' doesn't exist

insert into TABLE_DISCOUNT_COUPONS_USE_COUNT (coupons_id, orders_id) values ('reduc5', '32')

[TEP STOP] "

It's the same even with the max use = 0 or 1

Of course the Table doesn't not exist ... and i can't find where i did this mistake ... i can't see either in the install.txt something about this table ...

Thanks for the help

Phil

#76   kgt

kgt
  • Members
  • 2,883 posts
  • Real Name:KG Thorson

Posted 13 June 2006 - 15:16

Hi
This contribution is what i really need /wink.gif' class='bbc_emoticon' alt=';)' /> but ...

I have manually installed the last version ... everything works fine until the last validation
( I can create a discount coupon, i can valid the cart, the price is exact with the discount, etc ... )
then i get this error message :

" 1146 - Table 'db157787952.TABLE_DISCOUNT_COUPONS_USE_COUNT' doesn't exist

insert into TABLE_DISCOUNT_COUPONS_USE_COUNT (coupons_id, orders_id) values ('reduc5', '32')

[TEP STOP] "

It's the same even with the max use = 0 or 1

Of course the Table doesn't not exist ... and i can't find where i did this mistake ... i can't see either in the install.txt something about this table ...

Thanks for the help /wink.gif' class='bbc_emoticon' alt=';)' />

Phil


Lines 116-122 of checkout_process.php should be:

//kgt - discount coupons
  if( tep_session_is_registered( 'coupon' ) && $order->info['coupon'] != '' ) {
	  $sql_data_array = array( 'coupons_id' => $order->info['coupon'],
													   'orders_id' => $insert_id );
	  tep_db_perform( TABLE_DISCOUNT_COUPONS_TO_ORDERS, $sql_data_array );
  }
  //end kgt - discount coupons

Replace the code you have with this.

#77   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 16:56

Okay. I copied the list you sent me and I overwrote the bad list. MAGIC! Suddenly, I feel a little better, like I might not be brain dead after all. But, all I fixed was the presentation in the middle section of the graphics - which are still at the dead bottom of the page, after the still present column of code. And the side bar graphics and all of the titles are still bad - Header_Title_Top>>Header etc. Box_Heading_Whats_New Stuff like that. So I haven't solved the bulk of the problem.

Any other wisdom?


Problem Solved: we are on a remote computer, editing code on a server, several pages at a time. Evidently, our cat/includes/lang/eng.php file had become corrupted, or inadvertently edited, and the code had been truncated. We went back to the server, generated a fresh store, copied the code from that fresh source, closed the source and pasted the code into the real store file. Everything is working now. I just want to record this in case there are other store owners out there who are as green as php as we are and might have gotten themselves into the same kind of fix.

Like I said, the symptoms are these: you go to a page, and it has a huge glob of code there instead of the lovely thing you expected to see.http://forums.oscommerce.com/style_images/1/folder_post_icons/icon8.gif

My deep appreciation for the help.http://forums.oscommerce.com/style_images/1/folder_post_icons/icon12.gif

#78   WingingIt

WingingIt
  • Members
  • 33 posts
  • Real Name:Kristen Randle

Posted 13 June 2006 - 16:59

Okay. I copied the list you sent me and I overwrote the bad list. MAGIC! Suddenly, I feel a little better, like I might not be brain dead after all. But, all I fixed was the presentation in the middle section of the graphics - which are still at the dead bottom of the page, after the still present column of code. And the side bar graphics and all of the titles are still bad - Header_Title_Top>>Header etc. Box_Heading_Whats_New Stuff like that. So I haven't solved the bulk of the problem.

Any other wisdom?


Problem Solved: we are on a remote computer, editing code on a server, several pages at a time. Evidently, our cat/includes/lang/eng.php file had become corrupted, or inadvertently edited, and the code had been truncated. We went back to the server, generated a fresh store, copied the code from that fresh source, closed the source and pasted the code into the real store file. Everything is working now. I just want to record this in case there are other store owners out there who are as green as php as we are and might have gotten themselves into the same kind of fix.

Like I said, the symptoms are these: you go to a page, and it has a huge glob of code there instead of the lovely thing you expected to see.http://forums.oscommerce.com/style_images/1/folder_post_icons/icon8.gif

My deep appreciation for the help.http://forums.oscommerce.com/style_images/1/folder_post_icons/icon12.gif

#79   mpower

mpower
  • Members
  • 3 posts
  • Real Name:Dave Verzijl
  • Location:Rotterdam, the Netherlands

Posted 13 June 2006 - 17:36

You're not going to see the order total line for the discount coupon in Paypal. Paypal displays the subtotal, the shipping, and the total. You should make sure you have "Display Subtotal with Applied Discount" set to true in Modules > Order Total > Discount Coupons. Verify that your subtotal displayed by Paypal is the item total - discount + taxes, and the total is the subtotal + shipping.


I am transferring the shoppingcart to PayPal instead of an aggregate. Maybe that's why the total in PayPal doesn't correspond with the total that Discount Coupon Codes displays in the shop? I have set Display Subtotal with Applied Discount" to true.

Any idea ?

#80   philcopain

philcopain
  • Members
  • 2 posts
  • Real Name:Phil

Posted 13 June 2006 - 17:55

Lines 116-122 of checkout_process.php should be:

//kgt - discount coupons
  if( tep_session_is_registered( 'coupon' ) && $order->info['coupon'] != '' ) {
	  $sql_data_array = array( 'coupons_id' => $order->info['coupon'],
													   'orders_id' => $insert_id );
	  tep_db_perform( TABLE_DISCOUNT_COUPONS_TO_ORDERS, $sql_data_array );
  }
  //end kgt - discount coupons

Replace the code you have with this.


FANTASTIC !!!

Thanks a lot !! Everything is perfect now !!!