Support Forums

feature listings see in parent category

This is a discussion on feature listings see in parent category within the Modules / Plugins / Modifications forums, part of the Developer Forums category; Hi, I installed the feature_listings function in the template browse.tpl and I would like to see only the Featured ads ...


Go Back   68 Classifieds Forums > Developer Forums > Modules / Plugins / Modifications

Reply
 
Thread Tools Display Modes
Old 10-17-2009, 10:55 AM   #1
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default feature listings see in parent category

Hi,

I installed the feature_listings function in the template browse.tpl and I would like to see only the Featured ads in all main category and subcategory.

With this code, I only see feature Ads in their category.

Quote:
feature_listings_horizontal number=4 cat=$sec

I would like to see in each main categories, all featured ads including those in the sub-category

e.g.
In The main category Arts & Crafts, I would like to see all Featured Ads that are in their subcategory, Drawings, Paintings, Original Arts, Accessories, Sculpting.
Code:
Arts & Crafts --> Drawings
                  Paintings --> Original Arts
                                Accessories
                  Sculpting
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)

Last edited by hel68c; 10-18-2009 at 01:20 PM.
hel68c is offline   Reply With Quote
Old 10-17-2009, 02:11 PM   #2
Developer & Moderator
 
 
Join Date: Jan 2007
Location: Pennsylvania, USA
Posts: 2,311
Rep Power: 69
Mike-N-Tosh is just really nice Mike-N-Tosh is just really nice
Default

Serge,

In a v4.0.8 installation, css_featured_listings_horizontal is not part of the standard 68 classified plugins. Is this a third party plugin or one that you made? The one that does come with 4.1.x is css_featured. (I also don't know if that is backward compatible)

I don't believe that the variable $sec is available in the browse.tpl template file in v4.x installations.
__________________
Mike-N-Tosh
IndianaPC.org - A community website (v3.1.10 Developer - heavily modified & used as the CMS)
Sandbox [localhost(v3.1.10, v4.0.9, 4.1.10,4.2,5.0)] for development and customization
Visit My blog: reviews, tips, tricks, tutorials and my store with Templates, Mods & Docs
Web Hosting | Web Design & Development | 68 Classifieds Customizations
I am not a 68C employee, just a user and try to help out
Mike-N-Tosh is offline   Reply With Quote
Old 10-17-2009, 03:02 PM   #3
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default

Hi Mike,

The variable $sec is working fine with css_feature_listings "I made the change in category.php" but like I mention, it only display the Feature Ads in their category.

Do you have any advice on how?
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 10-18-2009, 01:20 PM   #4
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default

I tried function.feature_listings_horizontal.php version 4.1.2 and am unable to display feature Ads in their parent category.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 10-18-2009, 11:10 PM   #5
68 Classifieds Staff
 
Eric Barnes's Avatar
 
Join Date: Mar 2006
Location: Belmont, NC
Posts: 5,489
Rep Power: 135
Eric Barnes is just really nice Eric Barnes is just really nice
Default

You can see this page for parameters included:
Feature Listings Horizontal - 68 Classifieds

The category is not one included in the plugin.
__________________
Eric Barnes
68 Classifieds Developer
Customer Area | Issue Tracker | Documentation | 68C Mods | 68 @ Twitter | My Modules
Eric Barnes is offline   Reply With Quote
Old 10-19-2009, 04:48 PM   #6
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default

I understand that the category is not included in the plug in. I took at the tips & tricks from the 68classifieds Blog Featured listings by category.


I'm only asking if anyone has an idea of how to display all the ads in a main category and sub-categories from this plug in.

I just upgraded to the new version 4.1.6 and I am a little apprehensive about the conversion of all the changes I've made to version 4.08.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 10-28-2009, 09:44 AM   #7
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default

Hi,

I'm trying to get all the subcategory id from the module feature_listing_horizontal. I tried the code below and I only get one category. When I print_r $options['arr_childs'] in feature_listings_horizontal.php it display "Array ( [0] => 81 )".

When I print_r $options['arr_childs'] in category.php it display "Array ( [0] => 81 [1] => 82 [2] => 83 [3] => 129 [4] => 134 [5] => 228 [6] => 229 [7] => 252 [8] => 266 [9] => 271 [10] => 305 [11] => 332 [12] => 84 [13] => 227 )"

Do you know how to get all subcategory like category.php or how can I transfer the variable $options['arr_childs'] from category.php to feature_listings_horizontal.php?

Thanks

PHP Code:
 feature_listings_horizontal.php

            $slug
=$_GET['cat'];
            
$cat=$Categories->getCategoryBySlug($slug);

            
$sec=$cat['id'];

            
$arr_childs = array($sec);

            
$Categories->get_ids($arr_childs);
            
$options['arr_childs']=$arr_childs
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Old 10-28-2009, 11:59 AM   #8
All Hands On Deck
 
 
Join Date: Mar 2008
Posts: 3,342
Rep Power: 84
seymourjames is a jewel in the rough
Default

Why don't you try to take the relvant code out of category.php and use it in the plugin. Its the only thing I can think of.
__________________
"The fool doth think he is wise, but the wise man knows himself to be a fool.".

TemplateCodes.com for 68C, Version 4 Templates & Modules
Get the Best U.S Hosting, Best U.K Hosting
seymourjames is offline   Reply With Quote
Old 10-28-2009, 12:26 PM   #9
Customer
 
hel68c's Avatar
 
Join Date: Jun 2008
Location: Canada, Quebec
Posts: 289
Rep Power: 22
hel68c is just really nice hel68c is just really nice
Default

Quote:
Originally Posted by seymourjames
Why don't you try to take the relvant code out of category.php and use it in the plugin. Its the only thing I can think of.

that's what I did but despite several attempts, I can not have the subcategories ID.
__________________
Serge
HobbyClassified.com
V4.08 Developper, Module installed (CIV Scam Filter, Maffo Location System, Maffo News,Youtube, Seller Store)
hel68c is offline   Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
v4.0.x how to random listings in function feature listings horizontal hel68c Modules / Plugins / Modifications 2 07-02-2009 01:27 PM
Display sub-listings in parent category? wabugi Pre Sales Questions 2 03-14-2009 02:59 PM
how to get parent category name j890432m Technical Support 4 06-20-2008 04:30 PM


All times are GMT -4. The time now is 02:47 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2011, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0