Jump to content

jasehead

Member
  • Posts

    202
  • Joined

  • Last visited

Everything posted by jasehead

  1. I just exported a copy of my cubecart database prior to fiddling/upgrade and was browsing through when I noticed things like this in the CubeCart_search table: HTTP://SVZTGXEPMYEU.COM/ - or other random letter url always the same length (these were early on in the list so I expect they're old) SLEEP(3) - often as part of a longer string like '2015'&&SLEEP(3)&&'1' BENCHMARK(2999999 MD5(NOW())) الميرغني - or part/similar \\"X\\"=\\"X - or - 'X'='Y - or similar KM;L'/;M'/ SIDIVYA;VIDEOXXX;X I'm not sure what they might be sniffing for, but the MD5 suggests they are looking for a password weakness in the HTML output - and I guess they're testing if the search function mines the page code and not just the displayed text.
  2. I didn't want to delete the "What's New" category, just empty it. Using phpMyAdmin to run the SQL would bypass CubeCart having any say about deleting the secondary links in the index - unless it growls at me later. CubeCart safeguards against deleting a category (using CubeCart admin > Categories) that contains primary products so that there are no orphaned products as a result, but if all products were secondary it should be allowed. I'd still suggest that subcategories be protected - products gone but subcats remain - so the category could only be successfully deleted if no subcats. Much easier to move a few categories than hundreds of products. I understand that deleting the "What's New" category and reconstructing it would be a quick fix, but I'd have to make sure I didn't make other errors reproducing it. Anyway, next time I want to clear it out I'll backup the database, run the DELETE query and report back. Thanks for your time on this ?
  3. The WYSIWYG CKeditor for CubeCart product descriptions tends to clean up a lot of code to comply with the DOM (it's a "feature"). I like to include some comments in the product description for my own use, like whether the postage weight is accurate or search terms so I can email links to customers that will return groups of products, eg. <!--JANUARY-SALE--> Under certain circumstances, like changing text to BOLD or even changing details in the General tab, a cleanup occurs and comment tags can be deleted. It didn't seem to happen as often if the first thing I did when editing a product was to go to the description and select source - but I wanted to guarantee that it would not happen. So I've made two changes to includes/ckeditor/config.js CKEDITOR.editorConfig = function( config ) { config.allowedContent = true; // was bottom line, now moved to top config.filebrowserBrowseUrl = document.location.pathname+'?_g=filemanager&mode=fck'; config.protectedSource.push(/{[\s\S]*?}/g); config.protectedSource.push(/<!--[\s\S]*?\>/g); // allow <comment> tag config.extraPlugins = 'showprotected'; config.filebrowserWindowHeight = 500; config.filebrowserWindowWidth = 650; }; I also noticed that where some comments HAD been deleted, the comments that remained untouched were inside <p></p> tags, so I now include comments inside paragraph tags rather than just floating by themselves. For anyone else with other kinds of code tags being deleted, try a search for config.protectedSource.push to find the regular expressions you need. If changing the CKeditor config doesn't fix the problem, try nesting your code inside tags that seem protected.
  4. My focus was at the product level - just trying to detach the secondary category from 80+ products (not delete the category). My best guess for secondary categories was the category index table. If my DELETE query won't leave a trail of severed limbs in CubeCart, great - I'll use it next time. If this has helped with other issues, also great.
  5. Not sure if you have already worked out a solution for this. I suggest using the Print Order Form payment gateway and customising that as your CASH payment option - if anyone wants to pay on pickup/delivery. PayPal Standard would allow you to process PayPal and CC for customers who prefer to pay when they place their order. I would use Store Collection for the shipping gateway and have text on your site about free home delivery for orders over $299. Not sure how you're going to be able to offer an automated discount for cash, though you could manually adjust the order through Cubecart Admin and print a new invoice to give to the customer at the pickup/delivery stage. PayPal says that you CAN charge a surcharge, but that it can not be more than what they charge you (so you would need to check PayPal's payment fee formula) https://www.paypal.com/au/webapps/mpp/ua/useragreement-full#int_11_Receiving_funds You may need to employ a CubeCart developer to tweak your checkout/gateway for the cash discount/PayPal surcharge. BEST OPTION - you could just guess your ratio of Cash vs PayPal, split the difference and raise all your prices by 2%. That way your cash payments help to subsidise your PayPal payments and the overall cost to customers is minimal - a $50 item becomes $51. As an extra thought, you might consider a mobile PayPal Here device for processing card payments in person if you don't already have a way to accept cards on site.
  6. I have a What's New category - I use this as a secondary category for new products. I also add (NEW) to the product name. So I'm at the stage where my What's New category needs a refresh and I want to remove all products from it and start fresh. First of all, I ran this SQL query to remove the (NEW) from all products: UPDATE `CubeCart_inventory` SET `name` = replace(name, ' (NEW)', '') WHERE `name` LIKE '%(NEW)%' What I want to know is - can I run this SQL query to remove all products from my What's New secondary category (105), or am I going to do other damage and should instead MANUALLY change every product (about 80+) using Cubecart admin > Products > Categories tab DELETE FROM `CubeCart_category_index` WHERE `cat_id` LIKE '105' AND primary LIKE '0'
  7. I tried raising this as an issue six months ago but was beaten down: https://github.com/cubecart/v6/issues/1162 You can have any colour you like, so long as it's black.
  8. I'm using the By Weight shipping module in Australia and have set the two option names to Express Post and Parcel Post. The problem is, these option names are used for all international zones as well. Is there any way I can set Zone 1 to Express Post and Parcel Post for Australia, and have all the other international zones display Air Mail as the option 1 name?
  9. I find refunds or partial refunds via PayPal easy to deal with - it's just a matter of including admin notes in the order to say what was done and marking the order as cancelled. However, in CCv3 it used to be possible to back out of an order to return stock to the store - from Completed to Processing (save) then Pending (save) then Cancelled (final save). In CCv6 that process triggers some confusing automated e-mails to the customer and doesn't seem to return the stock, instead there has to be a manual adjustment. That's going to leave some statistical errors too because the database may record that five hats were sold but two were returned so only three were ever sold - meaning that you could restock a product that had issues or that actually didn't sell as well as the database says it did. +1 for managed stock returns in CCv6 - even if refunds are managed through PayPal and an admin note added to the customer order. Got to wonder if there IS an API for PayPal to manage refunds though (like PrestaShop) - it would be pretty neat. But I'm used to manually generating PayPal invoices to chase lost carts, and by comparison refunds are fairly quick. Adding a new order status is possible though - search the cubecart plugins for Partially Shipped for an example of how it's done.
  10. Actually, if the page is scrolled at all the back-to-top button in CubeCart invisibly blocks clicks for the tawk.to tab (bottom right corner) and makes it non-clickable. The back-to-top button and tawk.to tab are both visible and separate, but the tawk.to tab will only be clickable if the page is at top (not scrolled, so no back-to-top button visible). This is an annoyance that should be solvable with a little code mining - maybe the size of the area for the TOP button, or z-index?
  11. Now, in By Weight there are two option names available, eg. First Class, Second Class. Any suggestions for making the first option First Class for Zone 1 and Air Mail for all other zones (so it appears that way on customer orders)?
  12. Right, fixed. If you have changed line 33 in modules/shipping/By_Weight/skin/admin.tpl (to change the 4 to a 9 for example) {for $i = 1; $i <= 4; $i++} Then you also have to change line 73 in modules/shipping/By_Weight/shipping.class.php (so you would change the 5 to a 10 - or one more than the number of zones) for($i=1;$i<5;$i++){ Now I have LOTS of countries able to purchase again (including Romania) - wonder how many sales I lost in the meantime...
  13. In Countries/Zones, Romania has it's box checked OK. Nothing wrong with the weight:price array for Zone 8 - I exploded it to see if I'd missed a comma or colon but everything is fine and no error there. All items have a defined weight. I can't tell what the customer was ordering from within CubeCart, but if they ordered the same as last year it would likely be 0.569kg. The customer's last order was in a CCv3.0.17 store which has since been upgraded to 6.0.12 - in the admin/customer page I can see there is only a single address in the address book and not separate addresses for Default Delivery and Default Billing. So I'm wondering if I set those up that it might fix the issue? Clicking through their old order, I see Romania in their address book but in the Billing and Delivery tabs the country defaults to Afghanistan - because it's the first in the list I guess. Does that always happen for old orders from earlier CubeCart versions? In any case, if I go through Admin to login as the customer, I still see Romania as the address during checkout. I tried editing the address which creates a single billing/delivery address but checkout still came back with the "no suitable delivery methods" error. I then tried to use the address book (in admin) to add a default billing address but it WOULD NOT WORK - could not successfully create another address in the address book for this customer. I could edit the existing address, but couldn't add a second address as a delivery address (which is what other customers have - a Default Billing Address and a Default Delivery Address even though these are often the same. So then I tried it through the customer's address book and I COULD add two new addresses (default billing and default delivery, same as other customers) and delete the old address. Still the same error in checkout. I could try creating a new customer, but I'm starting to think I've explored the old-address-is-screwy scenario enough to discount it. === So I tried adding RO to Zone 1 - AND IT WORKED, no error. Zone 2 - worked Zone 3 - worked Zone 4 - worked Zone 5 and onward - NO SUITABLE DELIVERY ERROR That's pretty damning - adding extra zones to the By Weight shipping module looks OK but it's not working.
  14. Trying to trace why Cubecart is throwing this error (for a customer trying to purchase from Romania): "Unfortunately there are no suitable delivery methods available for your order. This may be because the total weight of your order is too high or we cannot deliver to your country. Please contact a member of our staff for any further inquiries." Currently using only the By Weight shipping plugin, expanded from 4 to 9 zones following Al's advice here: https://www.cubecart.com/extensions/shipping-methods/by-weight I've gone through gateway plugins - two are set to allow specific countries only, the third is PayPal Standard which has no countries allowed/disallowed so it should work worldwide. I've also gone through the By Weight plugin to make sure that the 22 disallowed countries do not include Romania and are not included in any of the ISO codes for the different zones. Doesn't appear to be any issues there. Have also checked for errors in the weight-price array but it seems fine. The only idea I have at this stage is that, even if 9 zones are enabled as per Al's advice, that somewhere the additional zones are being ignored. I have Romania in Zone 8.
  15. Is there any way to merge two customers? For example: a customer had 5 previous orders but had difficulty remembering their password so, instead of updating their password, they created a new login with a different e-mail address and password but all other details remain the same - only 1 new order for the new account. I was thinking this could be done in phpMyAdmin by searching for the new customer ID and replacing it with the original (or the other way around, depending on which one you wanted to keep). Suggestions? Ideas? Unseen issues?
  16. @ZeroX42 - I have tawk.to on my store (for me, it beats olark and zopim). Couldn't work out how to make a javascript work as a code snippet(!), so I just added the code to main.php in skins/foundation/templates/main.php after the last </div> tag and before the </body> tag. You may need to use the tawk.to dashboard to modify the tawk.to widget and get rid of the extra image because this blocks some of the page. You should also pay some attention to whether the widget blocks cubecart's back-to-top button on page scroll. Also check how the widget displays and works differently on desktop/tablet/mobile. I find it very good - the mobile phone app is a must and I can answer tawk.to alerts on the run. Customers must be answered right away though (even with a "Let me check...") otherwise they leave. As an admin, during store testing I use the tawk.to widget to record notes to follow up later. It's good how it tracks what page is being viewed as part of the conversation. @bsmither - tawk.to is offered as a block of javascript to be added to the end of a web page (just before the </body> tag). I was hoping that the code snippet function in cubecart would handle exactly that but I couldn't work out how to get it to work. Just adding the block of javascript intended for HTML as a code snippet didn't work. Does it need to be phpified a bit first?
  17. One thing though, about the radio buttons for postage auto-submitting - the radio buttons for payment methods also auto-submit on click. Is it possible to stop that behaviour, perhaps by adding .nosubmit class, without breaking the form? Like this? <input name="gateway" type="radio" value="{$gateway.folder}" id="{$gateway.folder}" class="nosubmit" required {$gateway.checked} rel="gateway_error"><label for="{$gateway.folder}">{$gateway.description}</label>
  18. Still suspicious of field_small_only in content.checkout.small.php, but I'll test it on a range of devices and browsers and see it there's an issue.
  19. Thank you bsmither. Radio buttons for shipping in content.checkout.medium-up.php are now working. Here's a summary for anyone else interested. In /skins/foundation/templates/content.checkout.medium-up.php Find this: <td colspan="4"> {$LANG.basket.shipping_select}: <select name="shipping"> <option value="">{$LANG.form.please_select}</option> {foreach from=$SHIPPING key=group item=methods} {if $HIDE_OPTION_GROUPS ne '1'} <optgroup label="{$group}">{/if} {foreach from=$methods item=method} <option value="{$method.value}" {$method.selected}>{$method.display}</option> {/foreach} {if $HIDE_OPTION_GROUPS ne '1'} </optgroup> {/if} {/foreach} </select> </td> Replace with this: <td colspan="4"> <p>{$LANG.basket.shipping_select}:</p> <ul class="no-bullet center"> {foreach from=$SHIPPING key=group item=methods} {foreach from=$methods item=method} <li> <input name="shipping" type="radio" value="{$method.value}" id="{$method.value}" {$method.selected|replace:'selected':'checked'}><label for="{$method.value}">{$method.display}</label> </li> {/foreach} {/foreach} </ul> </td> And in /skins/foundation/js/2.cubecart.js Find: $(".autosubmit select").not('.nosubmit').change(function() { Replace with: $(".autosubmit select, .autosubmit input[type='radio']").not('.nosubmit').change(function() { Still some tinkering to do, but I think that offering customers an immediately visible choice of shipping using a couple of radio buttons is much better than a select drop-down. Thank you again for your help, bsmither
  20. Grumble - still having other problems with the shipping select. In content.checkout.small.php there is this at line 86: <select name="shipping" class="field_small_only nomarg"> Well, on a small viewport in using my old version of Safari this doesn't work as a dropdown - it's just solid which means customers can't make a selection. If I remove the class, then this interferes with content.checkout.medium-up.php and the dropdown won't accept any changes - maybe there's a conflict in the code with using the name "shipping" because one control is just hidden, not absent from the code. My version of content.checkout.small.php is 100% Foundation - so I'm wondering if it affects medium-up then maybe it's causing some issue with the radio buttons. (Grasping at straws here)
  21. With that change the form submits on radio, but the problem now is that the radio button value will not change. On further testing, it's not defaulting to the cheapest value but to the last selected value. Once there's a selection it won't allow it to change - it returns the first selection only.
  22. For CubeCart v6.0.12 this seems to be in /js/common.js at line 109. $('select.update_form').change(function(){ $('input.required').removeClass('required'); $(this).parents('form').submit(); }); But I wasn't able to get it the code change to work, so returned it to how it was. I tried selecting the expensive radio button and then clicking the update basket button. It submitted/updated the form but the radio button defaulted to the cheapest option again. I tried adding onChange='this.form.submit();' to the input tag for the radio buttons (because I couldn't get update_form to work) but it again defaulted to the cheapest option. The drop-down select keeps its value on select/submit so I don't know what's going on. How do I make the radio option sticky when the form is updated? I'm OK with the cheapest option being chosen by default in the first instance, but I want any change to update the form with new shipping and total values and for the chosen radio button to remain checked after update.
  23. Tested and working - thank you. Although I've added conditional font awesome styles like this (if basket contains something): <i class="fa fa-shopping-cart{if isset($CONTENTS) && count($CONTENTS) > 0} other font awesome styles go here{/if}"></i> Still much less code than my first attempt.
  24. I sell a product where there is a small difference but most people can still use the product OK even if it's not the exact format they prefer. So, let's say I sell toy Zebras - some are white with black stripes, others are black with white stripes - most people don't care, they just want a zebra. If I run out of the black ones, isn't it better to just switch off the matrix status for that and just sell the white ones - the colour preference will still appear in the checkout, so if a customer has a real issue with the stripes then they might check it there. And I'll add a note in the Terms and Conditions to explain our policy about available colour options. I only deal with small quantities, so I often run out of one kind or the other. It would be much easier if the add to basket just worked for the remaining option rather than making the customer go to the product page and choosing the only option before they continue. And it would be great if I could just switch off one option in the matrix (or better for that to happen automatically when one option hit zero) rather than having to switch off all matrix options and rewrite the description only to have to undo everything again when new stock arrives. Like I said, small quantities, so stock levels fluctuate OFTEN. I can't just sell one kind of toy zebra, because I do get customers specifically wanting one kind or the other. I could make these two separate products, but they are very similar and I don't want to have to duplicate hundreds of other minor-difference products as well. Plus duplicate content = negative SEO.
×
×
  • Create New...