Zen Cart Logo
Forums / All Other Contributions/Addons / Reward Points Module for ZC v13x

Reward Points Module for ZC v13x

Locked

Views: 470,663

Results 1,561 to 1,580 of 2,476
This thread is locked. New replies are disabled.
9 Aug 2010, 3:26 AM
#1561
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Reward Points Module for ZC v13x

retched:

An easy way to answer this would be to check configure.php file for your ZenCart installation.

Open includes/configure.php in a text editor and look for define('DB_PREFIX', 'zen_');

Anything with the value listed in the second set of quotes, in my example 'zen_' is the database for ZenCart.

As for which database, look for define('DB_DATABASE', 'betadata');. That will list your zencart database. In my example, that is 'betadata'.

I found the file, sorry, looking in the wrong place. I found this text:

// define our database connection
define('DB_TYPE', 'mysql');
define('DB_PREFIX', '');
define('DB_SERVER', 'localhost');
define('DB_SERVER_USERNAME', 'UNHere_zc01');
define('DB_SERVER_PASSWORD', 'Password here');
define('DB_DATABASE', 'UNHere_zc01');
define('USE_PCONNECT', 'false');
define('STORE_SESSIONS', 'db');

The text in red was changed as to not give out sensitive information. But there is nothing next to DB_PREFIX but there is the zc01 that I saw once I was in the CPanel under databases. So I am assuming that is it. Thanks again. I will give this a try in the morning.

9 Aug 2010, 3:34 AM
#1562
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Reward Points Module for ZC v13x

retched:

While installing, did you make sure to make all of the changes in each folder?

If you mean change the folder names to my template then yes as can be seen here

http://nigel.geek.nz/sbo_shop/rpd.php

and as for the bits that show up in red, those bits all exist in the database, i checked

9 Aug 2010, 4:15 AM
#1563
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

lauriesscraps:

I found the file, sorry, looking in the wrong place. I found this text:

The text in red was changed as to not give out sensitive information. But there is nothing next to DB_PREFIX but there is the zc01 that I saw once I was in the CPanel under databases. So I am assuming that is it. Thanks again. I will give this a try in the morning.

What you were typing made me believe that you were referring to a prefix, this is a suffix you're talking about now.

Essentially use the name of the database that is given by the configure.php file. That is the database where zencart is installed.

9 Aug 2010, 4:17 AM
#1564
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

nigelt74:

Still can't get it to work

I turned on my error log and I have this error

[09-Aug-2010 14:38:22] StoreRewardPoints called but SESSION['REWARD_POINTS_EARNED'] not found

This seems to happen when i place the order

nigelt74:

If you mean change the folder names to my template then yes as can be seen here

http://nigel.geek.nz/sbo_shop/rpd.php

and as for the bits that show up in red, those bits all exist in the database, i checked

Ok. So you get those error messages you posted in your last message and then this one about SESSION[] not being stored...

Are you absolutely sure that you edited the files in the right manner?

In addition, when you created the tables and the modifications to the table, did you make sure that the datatypes of the table match those that rewards points are looking for?

9 Aug 2010, 4:33 AM
#1565
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Reward Points Module for ZC v13x

retched:

Ok. So you get those error messages you posted in your last message and then this one about SESSION[] not being stored...

Are you absolutely sure that you edited the files in the right manner?

In addition, when you created the tables and the modifications to the table, did you make sure that the datatypes of the table match those that rewards points are looking for?
according to the readme i have, there are no files to be edited.
There are 3 folders to be renamed which i have done
There is an sql script to be actioned, in my case it was new.sql
all of which i have done,

The sql script created the tables, so the datatypes should be correct, just no information is being put in them and the rpd file is showing those fields as being missing.

the datatypes appear correct to me looking at them through phpmyadmin

and yes my database uses a prefix zen_, but as you can see the rpd picks that up

-------------edit----------------------------

I'll state this now

It is working to a point, when i add products to my cart reward points are displayed in the left hand column, however when i check out, the reward points vanish they are not listed as pending nor are they applied, they are goneburger

9 Aug 2010, 5:05 AM
#1566
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

nigelt74:

I'll state this now

It is working to a point, when i add products to my cart reward points are displayed in the left hand column, however when i check out, the reward points vanish they are not listed as pending nor are they applied, they are goneburger

Is the order total modules installed and set to "True" in admin?

9 Aug 2010, 5:38 AM
#1567
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Reward Points Module for ZC v13x

retched:

Is the order total modules installed and set to "True" in admin?
you beat me to it

I just ticked the "reward points earned" and that fixed it, not sure how I missed that

I am still getting this in red though

Allow Redeem of Reward Points on Order Total or Subtotal- record missing in zen_configuration!!!

and I know it is set to zero(against subtotal) in admin

9 Aug 2010, 6:00 AM
#1568
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

nigelt74:

you beat me to it

I just ticked the "reward points earned" and that fixed it, not sure how I missed that

I am still getting this in red though

Allow Redeem of Reward Points on Order Total or Subtotal- record missing in zen_configuration!!!

and I know it is set to zero(against subtotal) in admin

0 is generally interpreted as FALSE in php or "not there" in PHP. Try setting it to 1 and rerun it.

9 Aug 2010, 6:16 AM
#1569
nigelt74 avatar

nigelt74

Totally Zenned

Join Date:
Sep 2005
Location:
Waikato, New Zealand
Posts:
1,558
Plugin Contributions:
1

Re: Reward Points Module for ZC v13x

retched:

0 is generally interpreted as FALSE in php or "not there" in PHP. Try setting it to 1 and rerun it.

makes no difference

9 Aug 2010, 6:28 AM
#1570
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

nigelt74:

makes no difference

Try to run your checkout again. If it works, this might one of those false positives.

If it doesn't, then you may want to check on the SQL you used to install.

9 Aug 2010, 7:27 AM
#1571
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Re: Reward Points Module for ZC v13x

I am working with my hosting company right now to get the MySQL file from a back up that was done by them on 7/31 which was a day before the wipe.

So As I am doing this, I also noticed that even with the updates, I am stll having a problem with my points going straight to earned. They are still being put into pending even when the sunrise period is set at zero.

Any ideas on that one? Thanks!

9 Aug 2010, 7:37 AM
#1572
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Re: Reward Points Module for ZC v13x

ok, I got MySQL file backup, now I just have to import it into the database. My hosting company says it would be too hard for me to make those changes to the way I import the file and it would be a lengthy process so he suggested getting someone to help.

He said:

The main gist of this is that you're going to have to remove some drop commands and modify some inserts, save the file with the changes and then import the dump in PHPMyAdmin

So I am too afraid to do it myself for fear I would screw everything up even worse. Can you help me with it or anyones else help me so I don't screw it up? Let me know what you would need if you are willing. Thank you.

9 Aug 2010, 9:54 AM
#1573
hem avatar

hem

Totally Zenned

Join Date:
Sep 2007
Location:
Dublin, Ireland
Posts:
1,281
Plugin Contributions:
5

Re: Reward Points Module for ZC v13x

lauriesscraps:

ok, I got MySQL file backup, now I just have to import it into the database. My hosting company says it would be too hard for me to make those changes to the way I import the file and it would be a lengthy process so he suggested getting someone to help.

He said:

So I am too afraid to do it myself for fear I would screw everything up even worse. Can you help me with it or anyones else help me so I don't screw it up? Let me know what you would need if you are willing. Thank you.

Laurie- just send the files to me, I think I still have access to your site.

9 Aug 2010, 11:04 AM
#1574
hem avatar

hem

Totally Zenned

Join Date:
Sep 2007
Location:
Dublin, Ireland
Posts:
1,281
Plugin Contributions:
5

Re: Reward Points Module for ZC v13x

nigelt74:

PHP Version 5.2.12
MySQL 5.0.90-community

But it still doesn't work as in when i make an order and mark it as dispatched no reward points are awarded

I'll add a link to the rpd file

http://nigel.geek.nz/sbo_shop/rpd.php

Check this line in the RPD:

Allow Redeem of Reward Points on Order Total or Subtotal- record missing in zen_configuration!!!

Try reinstalling upgrade.sql

9 Aug 2010, 3:37 PM
#1575
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Re: Reward Points Module for ZC v13x

hem:

Laurie- just send the files to me, I think I still have access to your site.

I only have one file. Should there be more? I also do not have your email, so if you could PM me with it that would be great!

You have access to my Zen Admin and to the FTP. They way they told me to do it required for me to import the file through the CPanel.

Let me know what you need.

9 Aug 2010, 7:16 PM
#1576
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Re: Reward Points Module for ZC v13x

lauriesscraps:

I only have one file. Should there be more? I also do not have your email, so if you could PM me with it that would be great!

You have access to my Zen Admin and to the FTP. They way they told me to do it required for me to import the file through the CPanel.

Let me know what you need.

Actually, the file is in my root directory. Is is has my username and then zc01.sql. Let me know if you need anything else.

Thank you!

10 Aug 2010, 4:42 AM
#1577
retched avatar

retched

Totally Zenned

Join Date:
Jun 2007
Location:
Bronx, New York, United States
Posts:
943
Plugin Contributions:
3

Re: Reward Points Module for ZC v13x

lauriesscraps:

ok, I got MySQL file backup, now I just have to import it into the database. My hosting company says it would be too hard for me to make those changes to the way I import the file and it would be a lengthy process so he suggested getting someone to help.

He said:

So I am too afraid to do it myself for fear I would screw everything up even worse. Can you help me with it or anyones else help me so I don't screw it up? Let me know what you would need if you are willing. Thank you.

This actually was what I was talking to you about in my post in regards to the change some of the SQL coding from INSERT INTO to INSERT IGNORE INTO and remove the delete tables. But I think you're getting help on this already. :)

10 Aug 2010, 9:15 AM
#1578
hem avatar

hem

Totally Zenned

Join Date:
Sep 2007
Location:
Dublin, Ireland
Posts:
1,281
Plugin Contributions:
5

Re: Reward Points Module for ZC v13x

lauriesscraps:

Actually, the file is in my root directory. Is is has my username and then zc01.sql. Let me know if you need anything else.

Thank you!

I don't see it. I can see a series of SimpleScript backups, is it one of those?

10 Aug 2010, 9:39 AM
#1579
hem avatar

hem

Totally Zenned

Join Date:
Sep 2007
Location:
Dublin, Ireland
Posts:
1,281
Plugin Contributions:
5

Re: Reward Points Module for ZC v13x

hem:

I don't see it. I can see a series of SimpleScript backups, is it one of those?

Nevermind, found it. Okay, all the Reward Point tables have been restored to the last backup.

10 Aug 2010, 2:54 PM
#1580
lauriesscraps avatar

lauriesscraps

Zen Follower

Join Date:
Sep 2009
Posts:
255
Plugin Contributions:
0

Re: Reward Points Module for ZC v13x

OH MY GOSH!!! Thank you! I just have to add a few that look like got overrided from orders over the last couple weeks but that is much better than having 3 pages of reward points to add! THANK YOU! You, once again, rock my world. I promise I will try to leave you alone now. Hahaha, thank you!