Jump to content

Alternative for getHomeCategories()


Recommended Posts

I'm trying to make a somewhat similar module as homefeatured2 (the homefeatured with random display).
In my module I at first wanted to display a number of products (as set in the BO) randomly, from all categories.
I couldn't get that to work, so I changed it into selecting the category in the BO and display random products from that categorie.. Now I can't get that to work either..
Seems the getHomeCategories() function (blockcategories.php is referring to it too) doesn't return anything.. All I get is an empty array..

Could someone point me in the right direction (on which function to use)? For either the first or second 'solution' (preferably both, so I can make a combination of 'em ;) ).

Link to comment
Share on other sites

Currently the featured products block is only showing products from the HOME category.
Since I don't want to place any products in the Home category itself, I want it to work just like it does now, but extract the products from all categories.
Preferably random products from all categories, but I'd also settle for random products from a selected category in the Back Office.

So, instead of showing products from the HOME category, show random products from ALL categories, or show products from a selected category in the BO.

I'm stuck at making a selection-list in the BO for the categories, since I'm only getting an empty array.

Hope this is more understandable ;) (I know I can rattle from time to time ;):P)

Link to comment
Share on other sites

OK Please upload progress if you are working offline, I would then require your to PM FTP & Back office details.
then I will take a look to see what you are doing wrong.

It would be useful to comment the code changed within your source first that way I will know where you are upto

Link to comment
Share on other sites

Ok.. I am not amused...
For some reason the testing with getting to view the categories, almost all categories are blank now.. Title and description only show -- (most of the products too, thank god I only had a few for testing purposes..).
No wonder I was only getting blank arrays.. the categories all lost their titles and stuff..

Back to square one I guess..

Link to comment
Share on other sites

Apparently I was being blond again.. ;) (I ám blond, so I have permission to say such things :P)
I added the English language yesterday so you could at least understand the backoffice. Because I changed the language of the BO to English, the names were empty by default, but ofcourse only for the English language (just found that out ;)).
So, problem 's nowhere near being solved as I want to, but I have a solution for the meantime: enter the id for the category manually. And that does work ;)

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...