Jump to content
dsaltmer

Questions about Enhanced Categories Box

Recommended Posts

There is a superfish addon somewhere that may work.


REMEMBER BACKUP, BACKUP AND BACKUP

Get the latest Responsive osCommerce CE (community edition) here

It's very easy to over complicate what are simple things in life

Share this post


Link to post
Share on other sites

is there anyway to add that with out having to change the layout in my template top php file. I like the look of the menu but it changes my boxes my buttons and my color scheme

Share this post


Link to post
Share on other sites

Although having had some beer and a little thinking time - maybe you could edit the images to make them smaller/shorter to make it fit your page a little better? Just a thought.

Share this post


Link to post
Share on other sites

Sorry that I'm late to the party. I wondered if anybody is still working through this or if everyone has given up hope?

I have devised a horibble and messy work around for the indentation issue. I found that trying to put the corrections in to my CSS file didn't work unless I specified every level of <li> in my store which was tedious. SO instead I did a little inline editing to the box.

 

In includes/modules/boxes/bm_enhanced_categories.php, on line 39, change:

$categories_string = '<ul class="enhcat">';

 

to:

$categories_string = '<ul class="enhcat" style="margin: -2px 0 0 -40px; list-style-type: none;">';

 

In includes/modules/boxes/bm_enhanced_categories.php, on line 39, change:

$categories_string = '<li>';

 

to:

$categories_string .= '<li style="margin-left: -' . ($cat['level']*15) . 'px;">

 

That gives a recurring negative margin of 15px per level. I did it like this because I couldn't find the actual problem. Maybe if I spent more time I could but it's late and I'm annoyed.

Also, it's only viable in FireFox and Chrome. IE pushes the menu too far to the left and it's useless. Then you're in to conditional statements and whatnot... sigh.

The Drop Down Menu at the bottom doesn't work because it calls a non-existent function on mine like this:

onchange="changePrice(this.id)"

I can't find where this changes because it should be:

onchange="this.form.submit(this.id)"

which works perfectly and yet changes back to the previous on page refresh.

 

All in all, it needs quite a bit of work (and a few files) but it's a base to work off if I (or anyone else) can be bothered.

Good luck.


Not enough time in the day. Need a time machine...

 

Would build one, but not enough time. Ironically.

Share this post


Link to post
Share on other sites

Ok, so my changePrice function was in my html_ouput.php file under the tep_draw_pull_down_menu function. My drop down works fine now.

It was obviously something that I'd put in and forgotten to take out again ages ago. :-

 

I'd still like to find the cause of the indentation issue though if anyone has any ideas. Or at least a work around for IE.


Not enough time in the day. Need a time machine...

 

Would build one, but not enough time. Ironically.

Share this post


Link to post
Share on other sites

Previous poster is right. The instructions give you the wrong file to add the code to. After putting the code into the proper file this worked for me. The file is /catalog/includes/functions/general.php

Share this post


Link to post
Share on other sites

Hi.

 

I've just installed this add on, and as it said in its description, it's a very easy install. However I have a couple of questions about it. In the install.txt the instructions say edit the file catalog/includes/general.php. This file doesn't exist in my install - there is however a general.php in catalog/includes/functions - is this the file I should edit, and if not should I create a general.php in catalog/includes? When I did install by editing the functions/general.php, the resulting categories box is very untidy, with every category and sub-category listed, the list not keeping inside the box. Thanks in advance.

 

Yes, the new function should be added to catalog/includes/functions/general.php as you suspected.

Share this post


Link to post
Share on other sites

Hi @@wdepot!

 

I just installed your tiny upgrade of the catagories box and it works! :-)

Just one little thing bothers me.

 

When showing catagories having sub-catagories, the mini triangle is shown at the left of the box. between its line and the next one.

 

Checked the code several times but I can't find the error......

 

Can you please help me out?

 

Thanx in advance

 

Kees

Edited by KeesB

Share this post


Link to post
Share on other sites

@@KeesB I know it's a while since your post, but it occurs to me that your problem may be the width of your info box, or the length of your category, causeing the sub-categorey icon to wrap.

 

Just a thought :)

Share this post


Link to post
Share on other sites

For people that want to know. For 2.3.4BS Gold

 

http://addons.oscommerce.com/info/8561

 

After a hour or so thinking and trying. I have managed to upgrade the Enhanced Categories Contribution to 2.3.4BS Gold.

 

Made a template enhanced_categories.php with

 

<div class="panel panel-default">
<div class="panel-heading"><?php echo MODULE_BOXES_ENHANCED_CATEGORIES_TITLE; ?></div>
<div class="panel-body"><?php echo $categories_string; ?></div>
</div>
 
and in the module file bm_enhanced_categories.php i changed the divclass calls, and added the template call.
 
      $output = '<div class="panel panel-default">' .
              '  <div class="panel-heading">' . MODULE_BOXES_ENHANCED_CATEGORIES_BOX_TITLE . '</div>' .
              '  <div class="panel-body">' . $categories_string . '</div>' .
              '</div>';
              
      ob_start();
      include(DIR_WS_MODULES . 'boxes/templates/enhanced_categories.php');
      $data = ob_get_clean();
 
Greetings, Anne

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×