Guest Posted May 6, 2010 Posted May 6, 2010 Hi all, I have some buttons on my website which do not function correctly. These are on my homepage www.childrenseducationaltoys.co.uk and also in the category pages where I can see a list of previewed products before going to the actual products page, e.g. http://www.childrenseducationaltoys.co.uk/activity-mats-c-90.html when these buttons are clicked, it does take you to the shopping cart, but an empty shopping cart. It is not pulling the products into the cart. If I go directly to a products page e.g. http://www.childrenseducationaltoys.co.uk/rainbow-aquadraw-activity-mat-p-124.html and click the add to cart button, the product successfully goes into the shopping cart. Is there a way to either correct this problem or delete the buttons which don't work correctly? Thank you Andrew
Guest Posted May 6, 2010 Posted May 6, 2010 I have some buttons on my website which do not function correctly. These are on my homepage www.childrenseducationaltoys.co.uk and also in the category pages where I can see a list of previewed products before going to the actual products page, e.g. http://www.childrens...-mats-c-90.html when these buttons are clicked, it does take you to the shopping cart, but an empty shopping cart. It is not pulling the products into the cart. If I go directly to a products page e.g. http://www.childrens...-mat-p-124.html and click the add to cart button, the product successfully goes into the shopping cart. Is there a way to either correct this problem or delete the buttons which don't work correctly? You have to check your code. In your first example that dont work, it looks like this in the browsers header: http://www.childrens...art.php?sort=2a and this one which is working: http://www.childrens...opping_cart.php What is this '?sort=2a' in the not working link?
Guest Posted May 6, 2010 Posted May 6, 2010 You have to check your code. In your first example that dont work, it looks like this in the browsers header: http://www.childrens...art.php?sort=2a and this one which is working: http://www.childrens...opping_cart.php What is this '?sort=2a' in the not working link? I don't know what the "?sort=2a" is at the end of the url. I did have some contributions installed, (price break and payment without account), so perhaps there is a conflict?? Oh I should have mentioned, I am also using a very poor coded template which has caused numerous problems with trying to install contributions in the past. I have been trying to contact the person who installed these contributions, but I have not been successful. Any idea would be very much appreciated.
jhande Posted May 6, 2010 Posted May 6, 2010 Hey Andrew, Probably not the reply you were hoping for, but I would lose the template. You mentioned it's given you trouble already. Start with the basic osC install, add the security updates and with just a little tinkering you can get it to look like your template. But with the added benifit of the code working properly. I believe that way you'll save yourself lot's of headaches in the future. - :: Jim :: - - My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -
Guest Posted May 6, 2010 Posted May 6, 2010 Hey Andrew, Probably not the reply you were hoping for, but I would lose the template. You mentioned it's given you trouble already. Start with the basic osC install, add the security updates and with just a little tinkering you can get it to look like your template. But with the added benifit of the code working properly. I believe that way you'll save yourself lot's of headaches in the future. I have thought about that idea before, but I have spend too much time and money in my existing template just to start all over again. It is not my intention to keep the template forever. I am planning to either use the standard OSC design or upgrade to a decent template in the future, but for now I have to continue with what I have. At least until I start making some money for the money I have already spent. Surely it can't be that difficult to delete a couple of buttons now?
jhande Posted May 7, 2010 Posted May 7, 2010 Ok, the following is based upon a standard osC installation... 1) To turn off and not display the Buy Now in the product listings, such as this page - http://www.childrens...-mats-c-90.html. Go to your admin panel > Configuration > Product Listing. You will see a feature Title called - "Display Buy Now column". Click on that, then the Edit button, then change the number to zero. 2) If you want to try and fix the button, this is the 1st place to look: Open includes/modules/product_listing.php You should have an entry similar too (possibly around line 139): break; case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_width = '85px'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a>'; - :: Jim :: - - My Toolbox ~ Adobe Web Bundle, XAMPP & WinMerge | Install ~ osC v2.3.3.4 -
Guest Posted May 7, 2010 Posted May 7, 2010 Ok, the following is based upon a standard osC installation... 1) To turn off and not display the Buy Now in the product listings, such as this page - http://www.childrens...-mats-c-90.html. Go to your admin panel > Configuration > Product Listing. You will see a feature Title called - "Display Buy Now column". Click on that, then the Edit button, then change the number to zero. 2) If you want to try and fix the button, this is the 1st place to look: Open includes/modules/product_listing.php You should have an entry similar too (possibly around line 139): break; case 'PRODUCT_LIST_BUY_NOW': $lc_align = 'center'; $lc_width = '85px'; $lc_text = '<a href="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=buy_now&products_id=' . $listing['products_id']) . '">' . tep_image_button('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</a>'; Thank you. I went through the admin area to delete the but it now function. That worked correctly. See However, on the homepage there are still the option to add to cart. These boxes only appear when a new product is added. I went to Firefox and looked up the source. Apparently the line of code I need to delete is <a class="iinfo2" href="http://www.childrenseducationaltoys.co.uk/index.php?action=buy_now&products_id=222">add to cart</a> but I have no idea which file this would be in. I spent an hour looking through all the files but couldn't find anything. You help is very much appreciated. Andrew
Guest Posted May 7, 2010 Posted May 7, 2010 I spent an hour looking through all the files but couldn't find anything. You help is very much appreciated. Andrew Use this program to search for text in files: Windows Grep
Guest Posted May 8, 2010 Posted May 8, 2010 Use this program to search for text in files: Windows Grep Thank you. That program did work really well. I found the code in new_products.php. The only problem is that I tried to delete the strip of code, and the whole website went down.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.