Jump to content
kymation

[Addon] Categories Accordion Box for 2.3.1

Recommended Posts

The test version of osCommerce this was developed on is in a subdirectory, so I doubt that's the problem. Perhaps there is something wrong with your configure.php settings. You didn't show the complete path in the error message, so I can't tell if that's right or not.

 

If all else fails, there is one workaround that you can try. Copy all of the code from admin/includes/functions/modules/boxes/icon_selector.php and paste it in the bottom of catalog/includes/modules/boxes/bm_categories_accordion.php, just before the final ?>,

 

Regards

Jim

 

Hi Jim,

 

very good news to me, after trying to copy and paste the icon_selector.php to the bm_categories_accordions.php, I can edit and save the order number now.

 

However I have no luck with the

$file = '/some/path/to/includes/functions/modules/boxes/icons.txt';

I have changed the path to match my server path, but it doesn't seems can find the icons.txt still....

 

PS. I save the new path on bm_categories_accordion.php, where I copied the icon_selector.php code, right?

 

many thanks in advance.

 

Lyn

Share this post


Link to post
Share on other sites

There's some reason your server is not finding the file. Are you certain the server path is correct? You may need to ask your host to verify that.

 

If the path is indeed correct, I have no idea why it doesn't work.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Hey there, I installed version 1.1.2 today in osc 2.3.3 that I installed yesterday. My problem is this: http://www.emeraldrose.co.uk/shop/catalog/index.php

 

Can you see it?

 

I'm not supposed to have a 4th accordian box, but I do and it has some code inside it.

 

I placed all the relevant files in the right folders like the manual says, although I didn't have the catalog/admin/includes/functions/modules/boxes/ directory, so I had to just add that whole directory in.

 

Also, the placement is set at 1000, which is the smallest number out of all the boxes on the left, but it still wants to appear at the bottom.

 

I hope you can help me... Could you tell me if the way my accordian operates is the way it's supposed to operate?

 

By the way, I don't know how to flush the cache. In admin>tools>cache control I see "file does not exist" for all three items listed: Categories Box, Manufacturers Box, Also Purchased Module. In admin>configuration>cache I have the Use Cache set to false. Setting it to true doesn't make any difference.

Share this post


Link to post
Share on other sites

That's a new one. I haven't seen this before, so I'm going to have to ask you to try some changes and see if they work. First, find this code in includes/modules/boxes/bm_categories.php:

 

 $categories_string .= tep_href_link( FILENAME_DEFAULT, $cPath_new );
$categories_string .= '\';"';

 

and change it to this:

 

 $categories_string .= tep_href_link( FILENAME_DEFAULT, $cPath_new );
$categories_string .= '\'"';

 

Next, find this code:

 

 $categories_string .= ' active: ' . $category_active_id . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;

 

and change it to this:

 

 $categories_string .= ' active: ' . $category_active_id . PHP_EOL;
$categories_string .= ' })' . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;

 

Please let me know when you have uploaded the changes so I can see what effect they are having.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Thanks Jim, only problem is, my file doesn't have any of that code... However, /bm_categories_accordion.php does, so I changed the code there. And it's made no difference. :(

Share this post


Link to post
Share on other sites

Sorry, that was a typo in the file name. You got it right. Next try -- find this code:

 

	    $categories_string .= '  </div>' . PHP_EOL;
      $categories_string .= '  <script type="text/javascript">' . PHP_EOL;
    $categories_string .= '    $(function() {' . PHP_EOL;

 

and change it to this:

 

    $categories_string .= '  </div>' . PHP_EOL;
    $categories_string .= '  </div>' . PHP_EOL;
  	 $categories_string .= '  <script type="text/javascript">' . PHP_EOL;
      $categories_string .= '    $(function() {' . PHP_EOL;

 

Then find this code:

 

	  $data = '    <div id="categoriesMenu">' . PHP_EOL;
  $data .= $categories_string . PHP_EOL;
  $data .= '    </div>' . PHP_EOL;

 

and change it to this:

 

	  $data = '    <div id="categoriesMenu">' . PHP_EOL;
  $data .= $categories_string . PHP_EOL;

 

Again, please let me know if this helps.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

You still have a problem. There's an extra > at the beginning of every category that shouldn't be there. I'm out of ideas on this one. You could try to update your jQuery, jQuery UI, and theme files to the latest version.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Yeah, they are the latest version, I only got them off jquery website yesterday.

 

Edit: Oh and the '>' is actually the unselected icon carat-1-e. If you select the box, it changes to a star.

Edited by definitivefreak

Share this post


Link to post
Share on other sites

OK, that still looks wrong to me, but that may just be your font.

 

For the sort order, it looks like you have it between the Information and Currencies boxes. Try increasing the sort order value of your other modules. Also, you can have problems if any two modules have the same sort order, even if they are not all box modules, so check the sort order of your other modules as well.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Hi Jim

 

Many thanks for the great conttribution. I use it on a number of customer sites and it looks great.

 

I have a problem on a new site I am creating. If I use the default Redmond template all works fine as on my other sites. However on this new site I have changed the Jquery theme and have a problem with the display. I have applied the changes in 181 above and this has removed the strange code from the bottom of the menu, but I still have a problem with the top Category being open when the page is first loaded.

 

You can see the issue if you go to the site: www.net-gifts.co.uk.

 

Hope you can help me out

 

Thanks in advance

 

Steve

Edited by stevep2210

Share this post


Link to post
Share on other sites

It appears that jQuery has changed some of the defaults in the latest version. To fix this, find the following code in includes/modules/boxes/bm_categories_accordion.php:

 

 $categories_string .= ' },' . PHP_EOL;
$categories_string .= ' active: ' . $category_active_id . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;

 

and change it to this:

 

 $categories_string .= ' },' . PHP_EOL;
$categories_string .= ' collapsible: true' . PHP_EOL;
$categories_string .= ' active: ' . $category_active_id . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;

 

Not tested, so please let me know if this works.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Hi Jim

 

Thanks for the quick reply.

 

That closed it up, but now it's lost all the colours etc.

 

Left it for you to view

 

Regards

 

Steve

Edited by stevep2210

Share this post


Link to post
Share on other sites

Two problems.

1. I forgot a comma; the code should be:

 

 $categories_string .= ' },' . PHP_EOL;
$categories_string .= ' collapsible: true,' . PHP_EOL;
$categories_string .= ' active: ' . $category_active_id . PHP_EOL;
$categories_string .= ' });' . PHP_EOL;

 

2. You added the code instead of replacing it.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Hi Jim

 

Sorry, it's been a long day! Almost sorted, Just noticed though that it's not displaying the 2 products under that category, like it do's under the wedding category.

 

Steve

Share this post


Link to post
Share on other sites

That's working now. The menu only shows categories, never products. Your first category has two products and no subcategories, so the content under the tab is empty -- as it should be.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Thanks for bringing this change to my attention. I can't keep up on everything, so having a bunch of people checking things out really helps. Now I just need to put together a new package and upload it. When I have time....

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

@@kymation Was just about to ask about the last two issues before I found this thread. All sorted now, just wanted to say thanks for keeping on top of your work and providing support.

Share this post


Link to post
Share on other sites

Hi,

 

After upgrading my theme to a Jquery 1.9.1 instead of 1.8.6 based, a line break or similar is added betweem the icon and the category name, (see image)

Any ideas whats wrong, or how I can change that? My old costum 1.8.23 and 1.8.6 based themes works great, but when Im doing a new theme thats saves as 1.9.1 I get this linebreak.

 

box_accord.JPG

Share this post


Link to post
Share on other sites

Have you upgraded your jQuery and jQuery UI script files as well? These need to match the version of the theme.

 

Regards

Jim


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

Share this post


Link to post
Share on other sites

Have you upgraded your jQuery and jQuery UI script files as well? These need to match the version of the theme.

 

Regards

Jim

 

Aaaah....ofcourse I had forgotten to upgrade the jquery-ui js file... Thanks! =)

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

×