Reward points gone

Hi,



I noticed my reward points are not showing at the product page anymore… I uninstalled the add-on and installed it again, and then I got the following error:



Warning: mkdir() [function.mkdir]: No such file or directory in /home/site/public_html/core/fn.fs.php



So I assume there was something wrong with the permissions… (however that may happened!?). I fixed this, uninstalled and installed the add-on again, and this time it installed without errors. But still, no award points on my product page.



I then copied the template file(s) from another (working) shop, but it’s still not showing.



In development mode, I do see that it’s calling the reward points templates, and while checking out I do see the amount of points I get. So it’s working but not showing on the product page.



Is there something really obvious I’m missing here?



Thanks - Flo

Hmm, it seems like it does have something to do with permissions… I uninstalled again and installed… and got Permission denied in /home/site/public_html/core/fn.fs.php on line 114 again.



Anybody know how I Can fix this? I set the permissions in the VAR folder right I think…

The proper permissions settings will depend upon the type of server you are running on.



For example, depending upon your server configuration you may need to use 0755 for Directories & 0644 for Files, or you may need 0777 for Directories & 0666 for Files.



I have been using 0755 & 0644 on our server without problems for well over a year now.



There are some very detailed posts from 6-8 months ago regards to determining your server type along with the proper permissions required for each which should be helpful to you.



ALSO, after you determine the correct permissions needed for your server, then make sure you enter these permissions within your config.local.php file and double check this file after each upgrade to be certain they were not changed.

i have the same problem

permissions didn’t work.

no matter what permissions i have, with 2.1.2 was everything fine. the problem occured when i upgrade to 2.1.3

i opened i ticket and i am waiting but cs-forums users are faster and better

thanks

Use the owner/group of the public_html directory (the directory where your store is probably loaded). Look at the permissions of that directory. If it is 755 then use 755/644 for directories/files in your store. If it’s 777 then use 777/666.



Cscart could do this programatically on install and set the default permissions for the specific server in config.local.php if they chose to do so.

still don’t work

Thanks for the help!



It could be that I also have the problem since the upgrade, and that I just didn’t notice it until now. Everything was running fine on 2.1.2 … never a permission problem.



I’m also pretty sure all the permissions are set right so I guess this is a bug…? will play around some more tomorrow and see if I can get it fixed.

Ok, I got my reward points back with the fix found in the bugtracker:


  1. Open the /core/fn.catalog.php file located in the core directory of your CS-Cart installation.


  2. Replace the following part of code



    Code:

    fn_set_hook(‘get_additional_product_data’, $product, $auth, $get_options);

    with this one

    Code:

    fn_set_hook(‘get_additional_product_data’, $product, $auth, $params[‘get_options’]);
  3. Save the file.



    Still having permission problems when installing new add-ons though.

[quote name=‘tbirnseth’]Use the owner/group of the public_html directory (the directory where your store is probably loaded). Look at the permissions of that directory. If it is 755 then use 755/644 for directories/files in your store. If it’s 777 then use 777/666.



Cscart could do this programatically on install and set the default permissions for the specific server in config.local.php if they chose to do so.[/QUOTE]



Do you mean the permission of the public_html directory? The permission for that directory is set to 750 on my server!

[quote name=‘Flow’]Ok, I got my reward points back with the fix found in the bugtracker:


  1. Open the /core/fn.catalog.php file located in the core directory of your CS-Cart installation.


  2. Replace the following part of code



    Code:

    fn_set_hook(‘get_additional_product_data’, $product, $auth, $get_options);

    with this one

    Code:

    fn_set_hook(‘get_additional_product_data’, $product, $auth, $params[‘get_options’]);
  3. Save the file.



    Still having permission problems when installing new add-ons though.[/QUOTE]



    ye, i found this solution at cs-bugs . Thanks



    but i also have another problem. The “buy together” is gone by products page (customers). any idea?

[qoute]

Do you mean the permission of the public_html directory? The permission for that directory is set to 750 on my server!

[/quote]

Yes, if it’s 750 then you are running PHP/Apache with the user permissions of that directory’s owership. Otherwise PHP/Apache couldn’t access the site.

Mystery, mystery…



My add-ons work but also give errors when I install them like:



Warning: mkdir() [function.mkdir]: No such file or directory in /home/site/public_html/core/fn.fs.php



So, when installing an addon the file “/home/amazingy/public_html/core/fn.fs.php” is trying to create a directory for which its getting a permission denied warning. So you’d think its trying to create a directory under a folder of which the permissions/ownerships are not correct… but they are. I even tried to chmod 777 for core as well as addons directory but its still giving the same error when I install some add-ons.



Am I going crazy?

When you install an addon, the cache is cleared (both cache and compiled directories). this makes sense so any hooks provided by the addon will be picked up and any Registry settings it needs to make are incorporated.



If you are using the ‘files’ method for your back-end cache (see config.local.php) then it will try to make a ton of directories and subdirectories to support the Registry cache. I doubt it is a permissions problem. You are probably exceeding the “system” number of flies per directory (directories within directories are also files for this statment - it’s actually what’s called an inode).



I’ll bet you have a lot of product features and filters. This is the most common cause of too many files. I would suggest using the sqlite method instead of files.