Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Super Fish Navagation Menu Vertical Superfish


Recommended Posts

thanks for replying jim...

 

 

i was being lazy when i asked the questions,,I dont want the menu to look like that..What i am trying to do is get rid of left coloumn from product info page..As i got too many categories having a top horizontal menu is a no go for me.

 

i want to place a link in the header for categories as shown in the link.when customer clicks on it menu gets displayed. how do i call this menu from a link.

 

regards

 

nafri

Link to comment
Share on other sites

It takes a different menu structure. Here's one I made for a client. It uses the Header Footer Contents addon and is installed as a module. You can use it that way or modify it to use a different button to host the pulldown. Sorry, no instructions, but it's pretty easy to set up.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

  • 2 months later...

It takes a different menu structure. Here's one I made for a client. It uses the Header Footer Contents addon and is installed as a module. You can use it that way or modify it to use a different button to host the pulldown. Sorry, no instructions, but it's pretty easy to set up.

 

Regards

Jim

 

 

I installed it in the new version of header_footer_content_modules_v1.3

 

When reloading the page I have this result:

 

1054 - Unknown column 'c.categories_visible' in 'where clause'

 

select c.categories_id, c.categories_image, cd.categories_name from categories_description cd join categories c on (c.categories_id = cd.categories_id) where c.categories_visible = '1' and c.parent_id = '0' and cd.language_id = '1' order by c.sort_order

Link to comment
Share on other sites

This addon does not contain a horizontal menu, nor is it intended to. Feel free to do that yourself if you want it. You can then contribute it to the community like I did with my code.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Unfortunately I am not able to change the code.

 

Dear @@kymation

I think now you have been able to understand the meaning of my words.

I admire you for what you do.

If I were able to do what you do I would be the happiest man in the world.

At 65 years of age I can not learn yet another job. I have to settle only to put to good use what others do.

Link to comment
Share on other sites

  • 5 months later...

I have the contribution installed (v2.3 Superfish box 1.1) on a osCommerce 2.3.4 site and everything is working as it should (YAY!)

 

But - of course I must be difficult - LOL! I need it to do something that it doesn't do "out of the box".

 

Does anyone know a smoother way to edit the module to achieve a unique background color for each category than the method listed here: http://www.oscmax.com/forums/oscmax-v1-7-discussion/3667-different-background-color-each-category.html

 

My client wants each category to have it's own background color and it seems osC only allows you to add an image to a category - but not to set a background color for the category.  I'd rather not create 6 different style sheets to achieve this if I don't have to.

 

I'm open to suggestions :-)

 

 

~Tracy
 

Link to comment
Share on other sites

That is definitely doing it the hard way. You can target each level of the menu with CSS without the need for any code modifications. Just add something like this to the Superfish stylesheet:

 

 

.sf-menu li {
    /* box color for top-level menu items */
    background:		#BDD2FF;
}
.sf-menu li li {
    /* box color for second-level menu items */
    background:		#AABDE6;
}
.sf-menu li li li {
    /* box color for third-level menu items */
    background:		#9AAEDB;
}
.sf-menu li li li li {
    /* box color for fourth-level menu items */
    background:		#FAAEDB;
}
.sf-menu li li li li li {
    /* box color for fifth-level menu items */
    background:		#9AAE9B;
}

 

Note that the first part of this is already in the stylesheet, so don't duplicate those class definitions.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

@@TracyS

 

If it is really the category background colour you are trying to change it is nothing really to do with the Superfish thread??

 

Regards

Joli

 

Or are you trying to change the category headings in the superfish box??

To improve is to change; to be perfect is to change often.

 

Link to comment
Share on other sites

Well - I'm trying but not getting very far. The instructions listed at the above linked forum post need to be modified slightly.  Here is what I have done - but it is not yet working :-(

 

application_top.php - I added the code to find the category number (lines 5 & 8 below)

 

  if (tep_not_null($cPath)) {
    $cPath_array = tep_parse_category_path($cPath);
    $cPath = implode('_', $cPath_array);
    $current_category_id = $cPath_array[(sizeof($cPath_array)-1)];
    $superfish_number = $current_category_id;
  } else {
    $current_category_id = 0;
    $superfish_number = '';
  }

 

template_top.php - 5th line down in below code I added a php call to the category number

 

<?php // Start superfish categories box  ?>
  <script type="text/javascript" src="ext/jquery/superfish/js/jquery.hoverIntent.minified.js"></script>
  <script type="text/javascript" src="ext/jquery/superfish/js/superfish.js"></script>
  <script type="text/javascript" src="ext/jquery/superfish/js/supersubs.js"></script>
  <link rel="stylesheet" media="screen" href="ext/jquery/superfish/css/superfish<?php echo $superfish_number; ?>.css">
  <link rel="stylesheet" media="screen" href="ext/jquery/superfish/css/superfish-vertical.css">
  <script type="text/javascript">
    jQuery(document).ready(function(){
      jQuery('ul.sf-menu').superfish({
        animation: {height:'show'},   // slide-down effect without fade-in
        delay:     1200               // 1.2 second delay on mouseout
      });
    });
  </script>
<?php // End superfish categories box  ?>

 

I then created two stylesheets named superfish22.css and superfish23.css

I am attempting to change the background color of the main level - so in superfish_navbar.css I have commented out every line that sets a background code and in superfish.css, superfish22.css and superfish23.css I have uncommented the below line and set different colors:

 

.sf-menu li {
   background: #BDD2FF; 

 

However, after uploading all of the above, I have found that it changes the entire menu when I load category 22 or category 23 rather than setting the background color for that <li> specific to each category regardless of what page I am on.

 

I am half way there - LOL! Any ideas?

~Tracy
 

Link to comment
Share on other sites

Thank you Jim-  but this would only change the sub-categories wouldn't it? I need a different color for each <li> based on the category id in the superfish menu box :-)

 

 

That is definitely doing it the hard way. You can target each level of the menu with CSS without the need for any code modifications. Just add something like this to the Superfish stylesheet:

.sf-menu li {
    /* box color for top-level menu items */
    background:		#BDD2FF;
}
.sf-menu li li {
    /* box color for second-level menu items */
    background:		#AABDE6;
}
.sf-menu li li li {
    /* box color for third-level menu items */
    background:		#9AAEDB;
}
.sf-menu li li li li {
    /* box color for fourth-level menu items */
    background:		#FAAEDB;
}
.sf-menu li li li li li {
    /* box color for fifth-level menu items */
    background:		#9AAE9B;
}

Note that the first part of this is already in the stylesheet, so don't duplicate those class definitions.

 

Regards

Jim

~Tracy
 

Link to comment
Share on other sites

Hi Joli,

 

I am asking here because I am using the superfish contribution for the category menu. I believe this can be set in the stylesheet somehow? I need a different background color for each unique category id - instead of a different image.

 

Here is a graphic example:

http://tcdataweb.com/KKTestSite/images/superfish_example.jpg

 

@@TracyS

 

If it is really the category background colour you are trying to change it is nothing really to do with the Superfish thread??

 

Regards

Joli

 

Or are you trying to change the category headings in the superfish box??

~Tracy
 

Link to comment
Share on other sites

Do you mean that you're trying to change the color of the top-level categories? That's overridden by the jQuery UI theme, so it can't really be done without massive changes.

 

Or are you trying to change the background of all the sub-categories of each category? I just don't understand what you want.

 

Edit: After seeing the above example, you want to change the top-level category colors. As I said, you'll have to peel off the jQueryUI overrides first, then modify the Superfish code. That's going to be a messy job.

 

Regards

Jim

Edited by kymation

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Oops - I just found my original reply to this did post. My browser had a glitch and I didn't see my reply -sorry.

 

@@TracyS

 

If it is really the category background colour you are trying to change it is nothing really to do with the Superfish thread??

 

Regards

Joli

 

Or are you trying to change the category headings in the superfish box??

Edited by TracyS

~Tracy
 

Link to comment
Share on other sites

@@Xpajun

 

Well was wondering if Julian had an answer if you look at his image

 

post #114

 

on this thread

 

http://www.oscommerce.com/forums/topic/393600-addon-superfish-categories-box/page-6

 

You see on the left hand side he has a small logo for each individual category  box heading no idea how he done 

 

but would be a small step I think to make this a background colour!!

 

Just thinking here again which sometimes does not work LOL

 

He posted the code for the category images but can not actually see how he managed the logos unless some photoshop magic

 

Regards

Joli

 

PS: yes just seen you post we are talking same thing brain is still working haha

Edited by joli1811
To improve is to change; to be perfect is to change often.

 

Link to comment
Share on other sites

Ewww.  :x

 

Well - I'll do a little more searching to see if there is a way to do this with the base category module that comes with osC and go from there. That might be easier? Maybe? LOL!

 

Do you mean that you're trying to change the color of the top-level categories? That's overridden by the jQuery UI theme, so it can't really be done without massive changes.

 

Or are you trying to change the background of all the sub-categories of each category? I just don't understand what you want.

 

Edit: After seeing the above example, you want to change the top-level category colors. As I said, you'll have to peel off the jQueryUI overrides first, then modify the Superfish code. That's going to be a messy job.

 

Regards

Jim

~Tracy
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...