♥JcMagpie Posted June 27, 2018 Share Posted June 27, 2018 Support thread for Categories navbar v2.3.4.1CE Categories navbar v2.3.4.1CE This is an update and mod of an old addon so all credit goes to original author. A simple addon to let you place a Categories menu in the navbar. You have 2 option a) simple based on stock bootstrap b) fancy based on additional css. In……….. /includes/modules/navbar_modules/templates……… You have 2 files, tpl_nb_horizontal_multi_menu.php and tpl_nb_horizontal_multi_menu.fancy The simple version is installed as stock. If you wan the fancy version then rename the files as required (change .fancy to .php) Simply install all the files and install “Horizontal multi menu ” addon and turn on in admin. You can play around with the css to get the look as you like but best to do this in user.css and not the responsivemultimenu.css. Fancy option will only work if you install all the files. It has been tested on the v2.3.4.1 CE Only. Link to comment Share on other sites More sharing options...
allaboutwicker Posted July 2, 2018 Share Posted July 2, 2018 Hi @JcMagpie Thank you for your contribution. I have installed this on my website and need some CSS help perhaps? On the homepage I get just the top categories show and all is ok, but any other page the subcats pop out and go way off the lower screen and I cannot scroll to see all of the items in the box. Can I make the wording space wider so it will not go so far down or I guess I can just have the top cats show on all pages as at least those will be shown. Thanks for any advice. Link to comment Share on other sites More sharing options...
♥JcMagpie Posted July 3, 2018 Author Share Posted July 3, 2018 Ok I see your problem , Long lists of cat's have always been a problem. Yes you can change the size in css so the line is longer. Just right click in browser and inspect elements and just make the changes in user.css or just add to your user.css and play with it until your happy. .dropdown-menu { width: 300px !important; height: 400px !important; } Alternatively ask one of the developers if they have a better cat’s addon. I am sure they probably do. Mine are just simple quick ones done for my sites. Link to comment Share on other sites More sharing options...
♥JcMagpie Posted July 3, 2018 Author Share Posted July 3, 2018 Try this instead, set the width and max hight to what you need. It will make any over flow scroll. Just be careful messing with too much css can make your site less mobile friendly. Bootstrap is a bit clunky but it’s a comprise between large screens and small. .dropdown-menu{ width: 250px; white-space: normal; max-height: 100px; overflow-x: hidden; } Link to comment Share on other sites More sharing options...
♥JcMagpie Posted July 3, 2018 Author Share Posted July 3, 2018 Had a play with the css and I think its better to change the code a little, so try this file and see, just replace in includes/modules/navbar_modules/templates/ You can see how it behaves on the test site, I think this is beter for the mobile view. https://www.justfastfood.com/ tpl_nb_horizontal_multi_menu.php Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 13, 2018 Author Share Posted December 13, 2018 JcM-categories-navbar-V1.2 CE BS4/3 It has been updated make it works with BS4 and allow styling to be configured in admin. A simple addon to let you place dynamic categories into the Navbar. Again totally stand alone with no core code changes. Simply copy all files into relevant sections and go to admin modules /content and install. Enjoy. As allways can be seen on the test sites. BS4 https://chilleddisplays.co.uk/ BS3 https://www.justfastfood.com/ Link to comment Share on other sites More sharing options...
nedragdnuos Posted December 14, 2018 Share Posted December 14, 2018 Hi, I am slowly in the process of rebuilding my shop with the latest CE version of OSC and have just installed your contribution as the very first addon after a clean install on my XAMP testing server I am using the latest version of the addon that you just uploaded: PHP Version: 7.2.12 (Zend: 3.2.0) The zip file also appears to be missing the fancy version of the file for the schmick looking menu. Any help or suggestions would be great, I do not have any coding experience as such, but managed to muddle my way through my last rebuild in 2014 to a shop that is still working on php5.6, but obviously would like to rebuild with the latest. Cheers! Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 You are using too high a version of php! drop to 7.2 and it should be ok. But I will have a look, it was tested on 7.2 and did not show any issues. The fix is simple simply define the constant. This is a trend with the higher php version they will cause more and more errors on old code. It will not affect the working of the add-on. Also there is no fancy in the new update 😊 you can change all the styling in the admin config. You can make it as fancy as you like. Link to comment Share on other sites More sharing options...
♥14steve14 Posted December 14, 2018 Share Posted December 14, 2018 4 hours ago, nedragdnuos said: Hi, I am slowly in the process of rebuilding my shop with the latest CE version of OSC and have just installed your contribution as the very first addon after a clean install on my XAMP testing server I am using the latest version of the addon that you just uploaded: PHP Version: 7.2.12 (Zend: 3.2.0) The zip file also appears to be missing the fancy version of the file for the schmick looking menu. Any help or suggestions would be great, I do not have any coding experience as such, but managed to muddle my way through my last rebuild in 2014 to a shop that is still working on php5.6, but obviously would like to rebuild with the latest. Cheers! If I am not mistaken you just need to find the code and add a ' and ' so that the code that is causing the error looks like the assumed code. Correct me if I am wrong. REMEMBER BACKUP, BACKUP AND BACKUP Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 4 hours ago, nedragdnuos said: Any help or suggestions would be great I have not been able to recreate the error you are getting on 2 live site both running PHP7.2 The line in question is, if (SHOW_COUNTS == 'true') { Perhaps you have your warnings set too high on your local host, but I'm no php expert! I'm sure someone will let us know if there is an error that needs fixing. Link to comment Share on other sites More sharing options...
♥raiwa Posted December 14, 2018 Share Posted December 14, 2018 The fix is: if ( defined('SHOW_COUNTS') && SHOW_COUNTS == 'true' ) { About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 Thank you @raiwa it's strange that I can not replicate this error on a live 7.2 site! However checking in php sand box fix works. Link to comment Share on other sites More sharing options...
♥raiwa Posted December 14, 2018 Share Posted December 14, 2018 In application_top.php: error_reporting(E_ALL); ini_set('display_errors','1'); Only during development, not for production/live site! About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 Yes I don't use that, I have it all errors dumped into erro_log file and yes as it's test site it has many error's in it, but not this one. Link to comment Share on other sites More sharing options...
♥raiwa Posted December 14, 2018 Share Posted December 14, 2018 Then there may be something wrong in Steve's @14steve14 installation. Uninstall/reinstall the module? Edit: Just checked, SHOW_COUNTS is not defined anywhere in your module. It maybe defined somewhere else in your test store and therefore you do not get this error. About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 Looks like my fingers were lazy again! Sorry find line /includes/modules/navbar_modules/templates/tpl_nb_horizontal_multi_menu.php on line 119 MODULE_NAVBAR_HORIZONTAL_MULTI_MENU_BORDERTBOTTOM and change to MODULE_NAVBAR_HORIZONTAL_MULTI_MENU_BORDERBOTTOM Link to comment Share on other sites More sharing options...
♥raiwa Posted December 14, 2018 Share Posted December 14, 2018 To clear this up: SHOW_COUNTS was used in standard oscommerce, but has been removed in the actual CE BS EDGE FROZEN series and was never in use in BS. The output where you use it in cat_navbar_responsive.php anyway is empty: if (SHOW_COUNTS == 'true') { $products_in_category = tep_count_products_in_category($key); if ($products_in_category > 0) { $output .= ''; } } so it should be removed or the configuration constant should be added to your module. It seems the code base used to create the category tree is outdated. It would be much easier (and efficient/faster) to use the core category_tree class or a variant of it like it has been done in this contribution: https://apps.oscommerce.com/42x4C&horizontal-categories-menu-bs About Me: http://www.oscommerce.com/forums/user/249059-raiwa/ Need help? How To Get The Help You Need Is your version of osC up to date? You'll find the latest osC community version CE Phoenix here. Public Phoenix Change Log Cheat Set on Google Sheets Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 16 minutes ago, raiwa said: It would be much easier (and efficient/faster) to use the core category_tree class Not in a position to pass jugment on this so thank for the feedback. something to consider for the next update if and when I have time. I already have a add-on that uses the stock cat's class 😊 I find this one is quicker and smother but hey thats just my view. https://apps.oscommerce.com/nytlE&jcm-header-categories Link to comment Share on other sites More sharing options...
Dj-Viper Posted December 14, 2018 Share Posted December 14, 2018 Hi, There is a update for this contribution online, added the language files for Dutch and German. Greetings, Anne Link to comment Share on other sites More sharing options...
nedragdnuos Posted December 14, 2018 Share Posted December 14, 2018 10 hours ago, raiwa said: if ( defined('SHOW_COUNTS') && SHOW_COUNTS == 'true' ) { The above fixed it............ and the spelling mistake in 7 hours ago, JcMagpie said: /includes/modules/navbar_modules/templates/tpl_nb_horizontal_multi_menu.php on line 119 MODULE_NAVBAR_HORIZONTAL_MULTI_MENU_BORDERTBOTTOM and change to MODULE_NAVBAR_HORIZONTAL_MULTI_MENU_BORDERBOTTOM Thank you all for your help, it is greatly appreciated! Enjoy your weekend! Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 14, 2018 Author Share Posted December 14, 2018 Glad you got it sorted. I have updated it to cover the errors and fix a few warnings being given on scripts. JcM-categories-navbar-V1.3 for v2.3.4.1 CE BS4 and BS3 Has been updated to fix errors. Also updated to replace js script for hover with css hover. This has required new files for BS3. Also BS3 setup for fancy as this was causing confusion. Link to comment Share on other sites More sharing options...
♥JcMagpie Posted December 15, 2018 Author Share Posted December 15, 2018 Some things to consider when reporting a problem with add-ons (this is for mine others may have different opinions) 1) I’m not a developer. I do this in what little spare time I have mainly for my own sites. So please understand although it may be urgent for you, I will not be able to drop things and look at the problem straight away. 2) Not everything you see as a problem is that urgent! You need to understand the errors and respond accordingly. It’s just a fact of life that if you have code you will have bugs and updates that need to be done. I don’t know any one professional or not that produces perfect code! I know I definitely don’t! So with osC the PHP will normally give you 3 main types of errors. ( many others but 3 main ones) a) E_ERROR Fatal run-time errors. These indicate errors that can not be recovered from, such as a memory allocation problem. Execution of the script is halted. Hopefully you should never see these as the code is broken and will not run, hence I will not have a successful test on my test site. There may be occasions when one is seen especially if you run the add-on on the wrong version of PHP. b) E_WARNING Run-time warnings (non-fatal errors). Execution of the script is not halted. A warning is a message saying "You are doing something wrong and it is very likely to cause errors in the future, so please fix it." I do my best to catch these but they will and do slip through the testing. Most of these will not stop the code running so you have to check the error logs to see them. Many are just what the word says warnings that can and are on many occasions ignored until the next update. c)E_NOTICE Run-time notices. Indicate that the script encountered something that could indicate an error, but could also happen in the normal course of running a script. A notice is an advisory message meaning "You probably shouldn't be doing what you're doing, but I'll let you do it anyway" These can be ignored and again will normally be dealt with in the next update. So hopefully this will help alleviate any panic you may have when looking at your error logs. I’ll do my best to fix issues that are posted. Link to comment Share on other sites More sharing options...
♥Dnj1964 Posted February 5, 2019 Share Posted February 5, 2019 Quote Version Checker Installed Version: osCommerce Online Merchant v2.3.4.1 CE PHP 7.1.25 Downloaded 1.3 and installed the files in their respective directories. Checked for the stray 'T' in /includes/modules/navbar_modules/templates/tpl_nb_horizontal_multi_menu.php and did that fix. Instructions are: Quote go to admin modules /content and install As there is nothing to install in /Content But going to Module / Navbar Modules creates a bunch of errors Quote Warning: include(/includes/languages/english/modules/navbar_modules/nb_horizontal_multi_menu-BS3.php): failed to open stream: No such file or directory in /admin/modules.php on line 142 Warning: include(/includes/languages/english/modules/navbar_modules/nb_horizontal_multi_menu-BS3.php): failed to open stream: No such file or directory in /admin/modules.php on line 142 Warning: include(): Failed opening '/includes/languages/english/modules/navbar_modules/nb_horizontal_multi_menu-BS3.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /admin/modules.php on line 142 Fatal error: Cannot declare class nb_horizontal_multi_menu, because the name is already in use in /includes/modules/navbar_modules/nb_horizontal_multi_menu.php on line 18 Hopefully I gave enough information that someone can steer me in the right direction. Thanks Link to comment Share on other sites More sharing options...
♥JcMagpie Posted February 5, 2019 Author Share Posted February 5, 2019 Warning: include(/includes/languages/english/modules/navbar_modules/nb_horizontal_multi_menu-BS3.php If using the BS3 files you need to rename them by removing the -BS3 from the end! so nb_horizontal_multi_menu-BS3.php will become nb_horizontal_multi_menu.php Link to comment Share on other sites More sharing options...
♥Dnj1964 Posted February 5, 2019 Share Posted February 5, 2019 10 minutes ago, JcMagpie said: Warning: include(/includes/languages/english/modules/navbar_modules/nb_horizontal_multi_menu-BS3.php If using the BS3 files you need to rename them by removing the -BS3 from the end! so nb_horizontal_multi_menu-BS3.php will become nb_horizontal_multi_menu.php Thank you From the Readme file I am using Responsive-osCommerce-master.zip osCommerce 2.3.4.1 + Bootstrap v4 (Shop Side) + jQuery + other external scripts Since it says Bootstrap 4 I deleted the BS3 file and the error went away, installed but nothing shows on site. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.