Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

CSS Menu


fear4me

Recommended Posts

  • Replies 250
  • Created
  • Last Reply

Top Posters In This Topic

How can i do, so it take the css fra the stylesheet file. ??? is direct in the file now.

 

Just cut the part between:

 

<style type="text/css">

 

and

 

</style>

 

and paste it into stylesheet.css.

 

Then the above tags can be removed from categories_css.php

 

Roger

Edited by fear4me
Link to comment
Share on other sites

I really like you CSS Menu. I installed it last night and it works great. Thanks for the contribution.

I do have a question. I know nothing about CSS but is there a way to make it only do the first subcategory and not any other sub category after that? Also instead of flying out to the right or left can it be a vertical pull down (for lack of a better term)?

 

Here is an example site with categories that pull down.

http://www.flashdesigntemplates.com/imageviewerplus_xl/

 

Click on the "Launch popup screen" selection and then take a look at there categories and you will see what I mean.

 

Thanks

Link to comment
Share on other sites

Ya you can hide cats with 0 prods:

 

 

Find the first section:

 

while ($categories = tep_db_fetch_array($categories_query)) {

 

if ($parent_id == '0') {

$categories_array[] = array('id' => $categories['categories_id'],

'text' => $indent . $categories['categories_name']);

} else {

$categories_array[] = array('id' => $path . $parent_id . '_' . $categories['categories_id'],

'text' => $indent . $categories['categories_name']);

}

 

 

CHANGE TO:

 

while ($categories = tep_db_fetch_array($categories_query)) {

 

if (!tep_count_products_in_category($categories['categories_id']) == 0) { // line added do not show categories with 0 products mod

 

if ($parent_id == '0') {

$categories_array[] = array('id' => $categories['categories_id'],

'text' => $indent . $categories['categories_name']);

} else {

$categories_array[] = array('id' => $path . $parent_id . '_' . $categories['categories_id'],

'text' => $indent . $categories['categories_name']);

}

} // line added from do not show categories with 0 products mod

 

 

Find the next section:

 

while ($categories = tep_db_fetch_array($categories_query)) {

if ($start_path == '') {

$grouppath = $categories['categories_id'];

} else {

$grouppath = $start_path . '_' . $categories['categories_id'];

}

$cPath_new = 'cPath=' . $grouppath;

 

 

CHANGE TO:

 

while ($categories = tep_db_fetch_array($categories_query)) {

if (!tep_count_products_in_category($categories['categories_id']) == 0) { // line added do not show categories with 0 products mod

if ($start_path == '') {

$grouppath = $categories['categories_id'];

} else {

$grouppath = $start_path . '_' . $categories['categories_id'];

}

$cPath_new = 'cPath=' . $grouppath;

 

 

And lastly find:

 

$returnval .= "<li><a href='" . $categories_string . "'>" . tep_image(DIR_WS_IMAGES . 'icons/arrow_red.gif', 'Available Selections', '4', '8') . '  ' . $categories['categories_name'] . "</a>";

 

 

CHANGE TO:

 

$returnval .= "<li><a href='" . $categories_string . "'>" . tep_image(DIR_WS_IMAGES . 'icons/arrow_red.gif', 'Available Selections', '4', '8') . '  ' . $categories['categories_name'] . "</a>";

 

} // line added from do not show categories with 0 products mod

Link to comment
Share on other sites

Thanks...excellent contribution! :thumbsup:

 

Only problem i've got :

When i enable sts, my categories is not displaying correctly anymore.

 

With STS enabled i've edited file : sts_column_left.php (categories.php to categories_css.php)

 

When i disable STS, everything displays 100% again!

 

Any help!

 

Thanks

Link to comment
Share on other sites

Thanks...excellent contribution! :thumbsup:

 

Only problem i've got :

When i enable sts, my categories is not displaying correctly anymore.

 

With STS enabled i've edited file : sts_column_left.php (categories.php to categories_css.php)

 

When i disable STS, everything displays 100% again!

 

Any help!

 

Thanks

 

Unfortunately I haven't got the time to test using STS. I'm not sure how STS exactly calls the categories-menu. What do you see when you include CSS Menu in STS? Do you have an URL?

Link to comment
Share on other sites

Great Contribution, as it just displays categories at the moment, does anymore plan to take this down to product level, be nice to have the complete inventory of products under the list.....

 

or am i missing something :)

Link to comment
Share on other sites

I think it would be useful that when someone finds their way through the menu to the spot they're at, the category they're in expands just like the original osc menu (like it shows all the subcategories underneath) so they dont have to navigate through the menu just to let's say, go to another subcategory in the same category. This make sense? :)

Link to comment
Share on other sites

I don't really want the CSS Menu now, but I'd like to keep the option of turning off menus with no products. Is there another contribution that does this, or can someone help me take out the necessary code and put it into my 'categories.php'?

 

Thanks!

Lisa

 

PS - this is a great contribution, I just cannot get it to work with the 'Simple Template System' contribution.

Link to comment
Share on other sites

Hi & thanks for this contribution. It has been very easy to install with brilliant functionality.

 

I have an issue using it though, it's not cos of the actual coding but just because of the way my site is setup.

The issue I am having is that I have an iframe which displays a gallery on the main page and although the menu works perfectly, when I get certain sub-categories inline with my iframe, they display but get hidden behind the iframe.

 

Is there a setting either in this menu or maybe in the iframe that i can adjust to make the menu stay in the foreground so it doesn't get hidden?

 

Any suggestions would be apprecited.

 

To see the issue I am having you can visit my test site

 

Visit demo site to see issue

Link to comment
Share on other sites

Hi & thanks for this contribution. It has been very easy to install with brilliant functionality.

 

I have an issue using it though, it's not cos of the actual coding but just because of the way my site is setup.

The issue I am having is that I have an iframe which displays a gallery on the main page and although the menu works perfectly, when I get certain sub-categories inline with my iframe, they display but get hidden behind the iframe.

 

Is there a setting either in this menu or maybe in the iframe that i can adjust to make the menu stay in the foreground so it doesn't get hidden?

 

Any suggestions would be apprecited.

 

To see the issue I am having you can visit my test site

 

Visit demo site to see issue

 

 

First I want to say, "awesome site, WOW",

Second, I'm having the same problem. Can anyone helps us?

Link to comment
Share on other sites

I'll release version 0.2 today with the option build in to show / hide subcategories with 0 items. I also added a cache-part, so the menu gets cached by osCommerce (thanks to 100asa).

 

CSS_MENU v0.2

I installed today the recent V2 and noted that it don?t work properly in Firefax 1.5.0.7 . V1 works great.

 

 

Andrew

Link to comment
Share on other sites

CSS_MENU v0.2

I installed today the recent V2 and noted that it don?t work properly in Firefax 1.5.0.7 . V1 works great.

Andrew

 

I also noted that the addition of the empty category in version 0.2 doesn't work properly... you could switch the empty-category option and the script should work again, but will show all categories, the empty ones included. I'll try to fix it this week.

Link to comment
Share on other sites

In a category with all the products inside disabled and the option to show empty categories set to true, the category still stays hidden.

 

Not an issue for me because I like the categories being hidden, just letting you know that setting the option to true doesn't work. Unless I screwed up. I just overwrote the newer version with my old version without looking at the readme.

Edited by yatahaze
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...