Jump to content
Sign in to follow this  
surfalot

[Contribution] Open Featured Sets Support

Recommended Posts

If I understand you correctly, neither option is available.

 

To choose categories to be featured, select the green button in the category list in the admin. If you want THE top (default unnamed category), you would have to select each top category individually. should be the same thing.

 

I'm not sure what you mean sort by top category. You can choose to sort by category name in the options. But not by Category Sort Order.

Thank you for responding.

I guess I was not clear in my previous post.

 

In the admin section when you go to catalog-->featured listings a list is displayed of all the featured listings that are selected and if they are active or not active.

 

I would like to add to that list which (top) category they belong to. And then if it is possible at all list them by (top) category.

 

Hope I am clear this time.

Share this post


Link to post
Share on other sites
Thank you for responding.

I guess I was not clear in my previous post.

 

In the admin section when you go to catalog-->featured listings a list is displayed of all the featured listings that are selected and if they are active or not active.

 

I would like to add to that list which (top) category they belong to. And then if it is possible at all list them by (top) category.

 

Hope I am clear this time.

Are you sure you have the correct support topic? Open Featured Sets doesn't have a menu item Admin -> catalog -> featured listings

Share this post


Link to post
Share on other sites

I want to show the category name in the infobox header rather than a standard name for all featured box headers.

 

i.e.

Box 1 = 1st Featured Category with it's category name (1) in the infoBoxheader.

Box 2 = 2nd Featured Category with it's category name (2) in the infoBoxheader.

Box 3 = 2nd Featured Category with it's category name (3) in the infoBoxheader.

 

It would be great to have the function in admin to turn this on or off too.

 

Can anyone give me some pointers where to find the code for this or has this mod. already been done.

 

Please help.

 

Thanks.

Share this post


Link to post
Share on other sites

Hi,

 

Installed your contirbution for featured products, categories and manufacturers and its fantastic.

 

I do have a small issue due to having installed categories description mod which enables the categories to be edited like the products are.

 

This means I have the feature selection in admin, but not the ability to set the feature dates etc as they are not available.

 

My guess would be I would need to make similar changes to the products in categories.php to the section relating to categories only.

 

Haven't a clue on how this would be coded.

 

If you need copies of any of the files I can provide the links so you can see the coding.

 

Thanks

Johnny


Getting better with mods but no programmer am I.

Share this post


Link to post
Share on other sites

it might help me understand what you are talking about if you provided a link to the categories contribution.

Share this post


Link to post
Share on other sites

Hi Surfalot,

Have been trying for some days to get your GREAT CONTRIB to work on osCommerce Online Merchant v2.2 RC2, with Mysql5 and Php 5.2.9, i get the following error "Fatal error: Call to a member function add_current_page() on a non-object in /homepages/xx/xxxxxxxxxx/htdocs/xxxxxxxx-online.com/includes/application_top.php on line 320". Do you have a clue what this can mean?? I think that this great contrib should be continued. Hope that you have an answer.

 

KEN

Share this post


Link to post
Share on other sites
Hi Surfalot,

Have been trying for some days to get your GREAT CONTRIB to work on osCommerce Online Merchant v2.2 RC2, with Mysql5 and Php 5.2.9, i get the following error "Fatal error: Call to a member function add_current_page() on a non-object in /homepages/xx/xxxxxxxxxx/htdocs/xxxxxxxx-online.com/includes/application_top.php on line 320". Do you have a clue what this can mean?? I think that this great contrib should be continued. Hope that you have an answer.

 

KEN

did you merge the files or copy them over (replace pages) on your site?

Share this post


Link to post
Share on other sites
did you merge the files or copy them over (replace pages) on your site?

 

Hi, i merged the files.

Claudia

Share this post


Link to post
Share on other sites

Hi Surfalot,

Forgot to mention, i have the header tags SEO contribution installed, could there be some conflict??

 

Claudia

Share this post


Link to post
Share on other sites
Hi, i merged the files.

Claudia

where you careful to only merge the code that was between these tags:

// BOF Open Featured Sets

// EOF Open Featured Sets

 

The files in this contribution are based on an older version of osCommerce. If properly merged, is should be just fine for osCommerce RC2, PHP5 and MySQL5.

 

Maybe offer a little more detail as to when it appears and the exact URL in your browser address bar when the error it appears. You can PM me the URL if you wish.

Share this post


Link to post
Share on other sites
Hi Surfalot,

Have been trying for some days to get your GREAT CONTRIB to work on osCommerce Online Merchant v2.2 RC2, with Mysql5 and Php 5.2.9, i get the following error "Fatal error: Call to a member function add_current_page() on a non-object in /homepages/xx/xxxxxxxxxx/htdocs/xxxxxxxx-online.com/includes/application_top.php on line 320". Do you have a clue what this can mean?? I think that this great contrib should be continued. Hope that you have an answer.

 

KEN

Look at these.

 

Jack

Share this post


Link to post
Share on other sites
Look at these.

 

Jack

 

Thanks Jack, that helped. but new problem shows up.

 

Fatal error: Cannot redeclare tep_get_sub_categories() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:17) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 26

Share this post


Link to post
Share on other sites
where you careful to only merge the code that was between these tags:

// BOF Open Featured Sets

// EOF Open Featured Sets

 

The files in this contribution are based on an older version of osCommerce. If properly merged, is should be just fine for osCommerce RC2, PHP5 and MySQL5.

 

Maybe offer a little more detail as to when it appears and the exact URL in your browser address bar when the error it appears. You can PM me the URL if you wish.

 

Hi Surfalot, was able to solve the first problem, but heres the new one, it appears on the index.php

Fatal error: Cannot redeclare tep_get_sub_categories() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:17) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 26

 

Claudia

Share this post


Link to post
Share on other sites
Hi Surfalot, was able to solve the first problem, but heres the new one, it appears on the index.php

Fatal error: Cannot redeclare tep_get_sub_categories() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:17) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 26

 

Claudia

I'm hoping the other function isn't different so as to cause problems with this contribution. You can try this. Open /catalog/includes/functions/featured_sets.php

 

The first function is

  function tep_get_sub_categories(&$categories, $categories_id) {
$sub_categories_query = tep_db_query("select categories_id from " . TABLE_CATEGORIES . " where parent_id = '" . (int)$categories_id . "'");
while ($sub_categories = tep_db_fetch_array($sub_categories_query)) {
  if ($sub_categories['categories_id'] == 0) return true;
  $categories[sizeof($categories)] = $sub_categories['categories_id'];
  if ($sub_categories['categories_id'] != $categories_id) {
	tep_get_sub_categories($categories, $sub_categories['categories_id']);
  }
}
 }

change to this

if (!function_exists('tep_get_sub_categories')) {
 function tep_get_sub_categories(&$categories, $categories_id) {
$sub_categories_query = tep_db_query("select categories_id from " . TABLE_CATEGORIES . " where parent_id = '" . (int)$categories_id . "'");
while ($sub_categories = tep_db_fetch_array($sub_categories_query)) {
  if ($sub_categories['categories_id'] == 0) return true;
  $categories[sizeof($categories)] = $sub_categories['categories_id'];
  if ($sub_categories['categories_id'] != $categories_id) {
	tep_get_sub_categories($categories, $sub_categories['categories_id']);
  }
}
 }
}

if that causes other problems we may have to change the name of that function for the specific use in this conribution.

I'm curious, is there a "tep_get_sub_categories" function in this file on your shop? /catalog/includes/functions/general.php

Share this post


Link to post
Share on other sites
I'm hoping the other function isn't different so as to cause problems with this contribution. You can try this. Open /catalog/includes/functions/featured_sets.php

 

The first function is

  function tep_get_sub_categories(&$categories, $categories_id) {
$sub_categories_query = tep_db_query("select categories_id from " . TABLE_CATEGORIES . " where parent_id = '" . (int)$categories_id . "'");
while ($sub_categories = tep_db_fetch_array($sub_categories_query)) {
  if ($sub_categories['categories_id'] == 0) return true;
  $categories[sizeof($categories)] = $sub_categories['categories_id'];
  if ($sub_categories['categories_id'] != $categories_id) {
	tep_get_sub_categories($categories, $sub_categories['categories_id']);
  }
}
 }

change to this

if (!function_exists('tep_get_sub_categories')) {
 function tep_get_sub_categories(&$categories, $categories_id) {
$sub_categories_query = tep_db_query("select categories_id from " . TABLE_CATEGORIES . " where parent_id = '" . (int)$categories_id . "'");
while ($sub_categories = tep_db_fetch_array($sub_categories_query)) {
  if ($sub_categories['categories_id'] == 0) return true;
  $categories[sizeof($categories)] = $sub_categories['categories_id'];
  if ($sub_categories['categories_id'] != $categories_id) {
	tep_get_sub_categories($categories, $sub_categories['categories_id']);
  }
}
 }
}

if that causes other problems we may have to change the name of that function for the specific use in this conribution.

I'm curious, is there a "tep_get_sub_categories" function in this file on your shop? /catalog/includes/functions/general.php

 

Hi Surfalot, Thanks for your response. Changed the code, new problem now is:

Fatal error: Cannot redeclare tep_set_featured_status() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:33) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 35.

 

And no function called "tep_get_sub_categories" in /includes/functions/general.php

 

Claudia

Share this post


Link to post
Share on other sites
Hi Surfalot, Thanks for your response. Changed the code, new problem now is:

Fatal error: Cannot redeclare tep_set_featured_status() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:33) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 35.

 

And no function called "tep_get_sub_categories" in /includes/functions/general.php

 

Claudia

 

check your catalog/includes/application_top.php for two occurrences of this line:

require(DIR_WS_FUNCTIONS . 'featured_sets.php');

 

there should be only one like that.

 

the redeclare error for all the functions in /includes/functions/featured_sets.php usually means it is being loaded twice. don't see how that could be possible without maybe having that line twice in your application_top.php.

Share this post


Link to post
Share on other sites
check your catalog/includes/application_top.php for two occurrences of this line:

require(DIR_WS_FUNCTIONS . 'featured_sets.php');

 

there should be only one like that.

 

the redeclare error for all the functions in /includes/functions/featured_sets.php usually means it is being loaded twice. don't see how that could be possible without maybe having that line twice in your application_top.php.

 

Hi Surfalot,

Thank you very much! What would i do without you guys :rolleyes:

I love Open Featured sets, great contribution. Would also be a great idea to integrate with MSRP.

 

regards

 

C

Share this post


Link to post
Share on other sites
Thanks Jack, that helped. but new problem shows up.

 

Fatal error: Cannot redeclare tep_get_sub_categories() (previously declared in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php:17) in /homepages/18/xxxxxxxxx/htdocs/xxxxxxxxx-online.com/includes/functions/featured_sets.php on line 26

 

Hi Jack,

Thanks for your support, that solved my problem. I have installed your Header Tags SEO mod and everything works fine except for the category part, i will try to get back to you later after backtracking.

 

Regards

Claudia

Share this post


Link to post
Share on other sites

Figured it out!!! Back in 06 i guess i had tried to install this, and left some of the define() statements in the application_top.php

Share this post


Link to post
Share on other sites

Hi,

 

I've been tweaking the css styles of this contribution and have come across something:

 

Found this issue when stripping the image size down to fit that when a current product is selected that is in the featured_sets section too, then the image returns to its original size, like so:

 

 

2heczz5.jpg

 

been looking at the php code so that i can limit the featured sets to only show products that are not currently active in the main content area and I'm stuck :( help greatly appreciated!

Edited by mcfcben

Share this post


Link to post
Share on other sites

Hi Surfalot,

 

Great contribution, works perfectly. Was wondering if it was possible to add "focus manufacturer", just like the featured & category focus fields, it would be great if under a specific category, only the relevant featured manufacturers are shown. Nice enhancement to target customers to view products by a given manufacturer. If there is an easy code fix to impliment this - any guidance, would be greatly appreciated.

Share this post


Link to post
Share on other sites

Hi, I have not even got passed first base.

 

When I tried to load the sql file I received the following error message.

 

Error

 

SQL query:

INSERT INTO `configuration`

VALUES (

'', '<font color=blue>Show Featured Sets on Categories</font>', 'SHOW_FEATURED_SETS_ON_CATEGORIES', 'true', 'Would you like to see the Featured Sets displayed on the categories page?', 99, 2, '2004-01-01 03:30:00', '2004-01-01 03:30:00', NULL , 'tep_cfg_select_option(array(''true'', ''false''),'

);

 

 

MySQL said:

#1062 - Duplicate entry '0' for key 'PRIMARY'

 

 

Any ideas?

 

Thanks, michael

Edited by offie

Share this post


Link to post
Share on other sites

Hi all,

 

does anyone know how to make the featured products appear on more than 1 row?

 

Thank you

 

Dave

Share this post


Link to post
Share on other sites

ignore that last request, i'm not sure what i was doing wrong but its working fine now :)

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
Sign in to follow this  

×