Bravo List

Bravo List (http://www.bvlist.com/index.php)
-   Template Shares (http://www.bvlist.com/forumdisplay.php?f=26)
-   -   help category and subcategorie (http://www.bvlist.com/showthread.php?t=6283)

DARCK 10th April 2011 12:03

help ts 5.6 category and subcategory
 
2 Attachment(s)
Attachment 2835

help me please is create cateacory and subcategory

my browse.php

Attachment 2836

Marco 11th April 2011 19:37

hello darck

i believe you need genre mod ;)

take a search

DARCK 11th April 2011 20:00

1 Attachment(s)
Quote:

Originally Posted by Marco (Post 27533)
hello darck

i believe you need genre mod ;)

take a search

I want to display the image of the categories and subcategories the image of the category It, but all same

Attachment 2838

lafouine022 12th April 2011 05:30

no use genre mod you already subcategory!


in this query

PHP Code:

$query sql_query("SELECT ".($torrentspeed == 'yes' '(t.size * t.times_completed + SUM(p.downloaded)) / (UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(t.added)) AS totalspeed,' '')." t.*, c.id as categoryid, c.image, c.name as categoryname, u.username, g.namestyle {$from} LEFT JOIN categories c ON (t.category=c.id) LEFT JOIN users u ON (t.owner=u.id) LEFT JOIN usergroups g ON (u.usergroup=g.gid) ".($torrentspeed == 'yes' 'LEFT JOIN peers p ON (t.id=p.torrent)' '')." WHERE ".($showvisible "t.visible = 'yes' AND " "")."t.banned = 'no'".(isset($extraqueries) ? $extraqueries '').{$groupby}{$orderbyvalue} $limit") or sqlerr(__FILE__,__LINE__); 

remplace by this:

PHP Code:

$query sql_query("SELECT ".($torrentspeed == 'yes' '(t.size * t.times_completed + SUM(p.downloaded)) / (UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(t.added)) AS totalspeed,' '')." t.*, c.id as categoryid, c.image, c.name as categoryname, c.pid as categorypid, u.username, g.namestyle {$from} LEFT JOIN categories c ON (t.category=c.id) LEFT JOIN users u ON (t.owner=u.id) LEFT JOIN usergroups g ON (u.usergroup=g.gid) ".($torrentspeed == 'yes' 'LEFT JOIN peers p ON (t.id=p.torrent)' '')." WHERE ".($showvisible "t.visible = 'yes' AND " "")."t.banned = 'no'".(isset($extraqueries) ? $extraqueries '').{$groupby}{$orderbyvalue} $limit") or sqlerr(__FILE__,__LINE__); 

and remplace

PHP Code:

$torrent_image '<a href="'.$seolink.'" target="_self" /><img src="'.$BASEURL.'/'.$pic_base_url.$table_cat.'/'.$torrents['image'].'" border="0" alt="'.$categoryinfo.'" title="'.$categoryinfo.'" /></a>'

by

PHP Code:

$torrent_image '<a href="'.$seolink.'" target="_self" /><img src="'.$BASEURL.'/'.$pic_base_url.$table_cat.'/'.$torrents['image'].'" border="0" alt="'.$categoryinfo.'" title="'.$categoryinfo.'" /></a>';
//////
        
$cimg3 sql_query("SELECT * FROM categories WHERE type='c' and id =" .$torrents['categorypid']);
         while(
$catimg=mysql_fetch_assoc($cimg3))
    {
        
$catimg2'<a href="'.$BASEURL.'/'.$catimg['name'].'-c-'.$catimg['id'].'.ts"><img src="'.$BASEURL.'/'.$pic_base_url.$table_cat.'/'.$catimg['image'].'" alt="" title="'.$catimg['name'].'"/></a>';
    }
///// 

so look the variable $catimg2 ;)

is work for me :bubble:

DARCK 12th April 2011 18:53

subcategory
 
2 Attachment(s)
Quote:

Originally Posted by lafouine022 (Post 27536)
no use genre mod you already subcategory!

thank lafouine022

Attachment 2839

my browse.php:muscle:

lafouine022 12th April 2011 21:56

to save the SQL query use: /cache/category.php :secret:


All times are GMT +2. The time now is 02:40.

Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.