Contributions
Category Tabs with Subs
The category tabs with subs is a spin-off of Paul Marshall's Category Tabs. I love what was created but I wanted the sub-categories to show up for each category as it was selected. I also wanted to include a tab for the home page. While I was modifying this Mod, I realized that the category box in the left column was overkill. So I created an option to use just tabs, just the category box, or both and made this feature easily changeable from the admin backend. The color scheme is designed to run off the stylesheet.css and the tab graphics will update on the fly (because they are transparent). This is my first attempt at submitting a Mod and it is merely a modification of an existing one. I didn't upload it to the same tree due to the extensive changes I made. It may not fall into line with Paul's ideas of what he was trying to accomplish. This will give your oscommerce store front an Amazon type look and feel. Enjoy!
Expand All / Collapse All
Hey,
loved this contrib, just came up with this to hide the subs on the homepage. im sure some one can do this better but this is what i came up with
replace:
include(DIR_WS_INCLUDES . 'categories_subtab.php');
with:
if ($cPath > 1) {
include(DIR_WS_INCLUDES . 'categories_subtab.php');
}
else{
echo " ";
}
New in v2.0.1 Multi-Store Tabs
----------------------------
by OSJUNKIE
Feb 25, 2005
*This is only for stores which use the Multi-Store contribution!!
Feature:
- Enable ability to have category tabs and obey store assignments
Stuff needed added & tweaked
- Sub categories do not obey stores (I don't use the sub categories part) Use the sub category pictures.
- If sub categories were to work a nice drop down CSS addition would make this a hot naviagation piece.
- Category box & Tabs do not function together properly. (Category box does not display the listing correct) Now if you were a code genious I would code it so the sub categorys would appear in the category box.
Update v2.0:
- Last category ID now automatic, no need to update the php file when adding a category.
- Sub-categories display moved to separate file, so use it or not.
- Optional display of the home page in the first tab.
- Height and width of images put in DEFINE at the beginning of file categories_tab.php, no need to edit the whole code.
- Option to not show categories having sort_order=0 (note that if you use other categories boxes and advanced search, you
need to also look those files to add similar behaviour).
- STS code for categories tabs and sub-categories available in readme.txt.
- Installation instructions updated.
This version combines this mod with the other and:
1) it displays tabs of the main categories with sybs
2) the tabs are background transparent
3) you need to update the php file to set the category id of the last tab.
4) the images should go into the images/curve directory
5) the php file should go into the includes directory
in your header.php file :
where you want it place:
<table width="100%" cellspacing="0" cellpadding="0" border="0"); >
<tr>
<td align="right" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="right">
<tr>
<td colspan="2" align="center" valign="bottom" nowrap>
<?php include(DIR_WS_INCLUDES . 'categories_tab.php'); ?>
</td>
</tr>
</table>
</td>
</tr>
</table>
example at www.shopje.com
This version combines this mod with another but:
1) it only displays tabs of the main categories
2) the tabs are background transparent
3) you need to update the php file to set the category id of the last tab.
4) the images should go into the images/curve directory
5) the php file should go into the includes directory
in your header.php file :
where you want it place:
<table width="100%" cellspacing="0" cellpadding="0" border="0"); >
<tr>
<td align="right" valign="top">
<table width="100%" border="0" cellspacing="0" cellpadding="0" align="right">
<tr>
<td colspan="2" align="center" valign="bottom" nowrap>
<?php include(DIR_WS_INCLUDES . 'categories_tab.php'); ?>
</td>
</tr>
</table>
</td>
</tr>
</table>
example at www.crystallight.com.tw
subcategories didn't show when the categories_id was more than 1 char.
Replace $id[0][0] by $id[0] in the categories_tab.php file.
The category tabs with subs is a spin-off of Paul Marshall's Category Tabs. I love what was created but I wanted the sub-categories to show up for each category as it was selected. I also wanted to include a tab for the home page. While I was modifying this Mod, I realized that the category box in the left column was overkill. So I created an option to use just tabs, just the category box, or both and made this feature easily changeable from the admin backend. The color scheme is designed to run off the stylesheet.css and the tab graphics will update on the fly (because they are transparent). This is my first attempt at submitting a Mod and it is merely a modification of an existing one. I didn't upload it to the same tree due to the extensive changes I made. It may not fall into line with Paul's ideas of what he was trying to accomplish. This will give your oscommerce store front an Amazon type look and feel. Enjoy!
Note: Contributions are used at own risk.