Jump to content

BrockleyJohn

♥Ambassador
  • Content count

    1,311
  • Joined

  • Last visited

  • Days Won

    32

Reputation Activity

  1. Like
    BrockleyJohn got a reaction from ArtcoInc in Where to load jQuery   
    ...and this hook comes before footer_scripts so you can safely put scripts in there that depend on jquery.
    Incidentally they won't need to be document ready scripts in that position as the main document html has already loaded. Just the inner code should work fine and each one will save a (tiny) bit of parsing and processing, ie
    $('ul.dropdown-menu [data-toggle=dropdown]').on('click', function(event) { event.preventDefault(); event.stopPropagation(); $(this).parent().siblings().removeClass('open'); $(this).parent().toggleClass('open'); });  
  2. Thanks
    BrockleyJohn got a reaction from Moxamint in Header Tags & Sort Order   
    At the risk of stating the obvious, it affects the order they are processed.
    Whether this makes any further difference depends on what they are.
  3. Like
    BrockleyJohn got a reaction from Portman in Quick swap of fields in address book   
    Yes choose a different address format for the country in admin > Locations/Taxes > Countries
  4. Like
    BrockleyJohn got a reaction from SCH_001 in Customers bypassing shipping method   
    Maybe you haven't got instant update set up properly so they're not being forced to choose from your shipping methods. See
    https://library.oscommerce.com/Package&en&paypal&oscom23&express_checkout
  5. Like
    BrockleyJohn reacted to raiwa in Discount Code BS   
    New version uploaded:
    Version 5.1.0 Phoenix
    Changes:
    Removed support for earlier EDGE versions Fix for discount not showing on first page load in ship in cart order total module in shopping cart, disable "Apply" button until code is validated. Added sitewide hook for session unregister of discount code on logoff ( @burt, sitewide hook used for the first time 😀) This Package will be separated in a neew addon, once a proper label for Phoenix version is available.
  6. Like
    BrockleyJohn got a reaction from LeeFoster in Paypal Express error   
    so it's still the same issue!
    DIR_FS_CATALOG is now set to '' instead of a logical path.
    It should be '/customers/6/7 blah blah
  7. Like
    BrockleyJohn got a reaction from altoid in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @douglaswalker sorry Doug didn't think properly - you need to change the query string rather than the url
    RewriteCond %{QUERY_STRING} "^([^\s%20]*)(?:\s|%20)+(.*)$" RewriteRule ^ %{REQUEST_URI}?%1%2 [L,R]  
  8. Like
    BrockleyJohn got a reaction from SCH_001 in Quick Product Updates for osc 2.3+   
    version 3.1.1 is available for download from https://apps.oscommerce.com/Apps&XpKWd&quick-update-bs
    Sponsored by @supercheaphobb it includes options for working with prices including tax and adding a datepicker to the specials expiry date. It also fixes the manufacturer query error that @radhavallabh hit the other day but not the latest bug above.
    Update is simple - just copy the files. New options are added automatically when you access the page and set to default.
  9. Like
    BrockleyJohn got a reaction from SCH_001 in Quick Product Updates for osc 2.3+   
    version 3.1.1 is available for download from https://apps.oscommerce.com/Apps&XpKWd&quick-update-bs
    Sponsored by @supercheaphobb it includes options for working with prices including tax and adding a datepicker to the specials expiry date. It also fixes the manufacturer query error that @radhavallabh hit the other day but not the latest bug above.
    Update is simple - just copy the files. New options are added automatically when you access the page and set to default.
  10. Like
    BrockleyJohn got a reaction from SCH_001 in Quick Product Updates for osc 2.3+   
    version 3.1.1 is available for download from https://apps.oscommerce.com/Apps&XpKWd&quick-update-bs
    Sponsored by @supercheaphobb it includes options for working with prices including tax and adding a datepicker to the specials expiry date. It also fixes the manufacturer query error that @radhavallabh hit the other day but not the latest bug above.
    Update is simple - just copy the files. New options are added automatically when you access the page and set to default.
  11. Sad
    BrockleyJohn got a reaction from alex121121 in Discount Code BS   
    Of course it's possible! It sounds like you have much bigger problems than discount codes.
  12. Like
    BrockleyJohn got a reaction from douglaswalker in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @douglaswalker I've reproduced it on a couple of sites running this addon
    It's not unusual to see garbage urls in the logs - I reckon they are down to faulty spider databases. May not be worth worrying about
  13. Like
    BrockleyJohn got a reaction from vampirehunter in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @vampirehunter I recommend that you try to get the mysqli extension enabled for your installation. mysql is deprecated even on php 5.6 and not available on php7. It's possible that there are bits of code that don't work properly on this old extension.
  14. Like
    BrockleyJohn got a reaction from vampirehunter in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @vampirehunter I recommend that you try to get the mysqli extension enabled for your installation. mysql is deprecated even on php 5.6 and not available on php7. It's possible that there are bits of code that don't work properly on this old extension.
  15. Like
    BrockleyJohn got a reaction from vampirehunter in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    On shared hosting, it's usually implicit in your choice of php version. You'll likely need the host's help to get the right php.ini file set up. First, use the Server Info option in admin/tools and search for mysqli. If you have a section with that heading, the extension is enabled and there's an issue with the code somewhere. If you don't have that section, speak to your webhosts and if you need more help from us on here, start a separate thread because in that case it's not an SEO Urls issue
  16. Thanks
    BrockleyJohn got a reaction from tttim6575 in 500 Internal Server Error - When accessing admin page   
    For the actual fix, the next step is to upload the correct
    admin/includes/template_top.php
     
    You have made a step forwards already. When you access admin it successfully redirects to the login page before it throws a white screen.
  17. Like
    BrockleyJohn got a reaction from tttim6575 in 500 Internal Server Error - When accessing admin page   
    not if you only do this to the admin app_top file and not the catalog one!
  18. Like
    BrockleyJohn got a reaction from burt in Paypal App - Fee   
    You can't do that in the UK - how other European countries apply the regs I couldn't say.
    From ...
    The UK regs cover personal card payments and electronic payments but not cash and cheques. So you can charge more or less to people that pay with cash, cheques or company cards, but you have to charge the same to anyone paying with personal cards, paypal, applepay and so on.
  19. Like
    BrockleyJohn got a reaction from Dan Cole in Login with PayPal - changes required?   
    I'll try to have a look into this in the next couple of days and see what the impact is.
  20. Like
    BrockleyJohn got a reaction from altoid in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    Martin, you might be better off with a small change to the standard filter:
    function short_name($str, $limit=3){ $container = array(); if ( $this->attributes['SEO_URLS_FILTER_SHORT_WORDS'] != 'false' ) $limit = (int)$this->attributes['SEO_URLS_FILTER_SHORT_WORDS']; $foo = @explode('-', $str); foreach($foo as $index => $value){ switch (true){ case ( strlen($value) <= $limit && (! is_numeric($value)) ): continue; default: $container[] = $value; break; } } # end foreach $container = ( sizeof($container) > 1 ? implode('-', $container) : (sizeof($container) > 0 ? $container[0] : $str )); return $container; } ie. don't filter any numbers - the change is in the case line in the switch
  21. Like
    BrockleyJohn got a reaction from altoid in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @Jack_mcs Happy New Year! I trust you haven't worked all the way through.
    A good tip on the settings - it reminds me; one of my clients has the feature to add exceptions to the short words filter, and it's been such a long time I can't remember where it came from. Used it to be part of the addon, or was it extended for them?
  22. Like
    BrockleyJohn got a reaction from altoid in [CONTRIBUTION] Ultimate SEO URLs v2.1 - by Chemo   
    @altoid you can reduce the number of connections required with a simple edit, in the file seo.class.php, in the database handling class at the top, edit the function ConnectDB so that it is simply:
    function ConnectDB(){ global $db_link; $this->link_id = $db_link; } This makes the class reuse the connection that you already made with tep_db_connect, so each page request only needs a single connection.
  23. Like
    BrockleyJohn got a reaction from joe122joe in NEW! Complete Order Editing Tool!   
    @joe122joe they aren't errors, just notices which you shouldn't be displaying in production. Some are things that didn't get noticed in earlier versions of php, some are just lazy coding but you can ignore them.
  24. Like
    BrockleyJohn got a reaction from joe122joe in NEW! Complete Order Editing Tool!   
    @joe122joe You have extra stuff in the beginning of includes/languages/english/modules/shipping/flat4.php before the <?php
  25. Thanks
    BrockleyJohn got a reaction from ArtcoInc in PHP 7   
    @ArtcoInc generally speaking, it shouldn't be a problem. There is syntax on 7-7.2 that isn't supported on 5.6 but you're probably not going to be using any of it in your new version... spaceships <=>, null coalescing ($action = $_GET['action'] ?? 'default'), anonymous classes, constant arrays and a bunch of other things that don't spring straight to mind.
    The only bit of code I can think of that doesn't work across versions is something to do with error-handling on evals but you probably haven't got any of that anyway. The evaluation order in statements is the other way round (eg. when working out what $$class->$method($param[$$key]) means but that should have been fixed by putting in curly braces to make it expllicit in the statement.
    The approach would be - get a set of code running without issue on 7 and then turn the version back down to 5.6 for a test.
    hth
×