Web Development Logs
Find articles, news and reviews about latest technologies.


Welcome Guest !
please login or register a new free account.


Home | Archives | Submit Article | Top Rated | Advance Search | Contacts Us | Rss Feeds

    Main Categories
» Free downloads
» General Blog
» Google Adsense
» Scripting languages
» Search Engines
» Web Designing

  More Options
» Most read articles
» Most rated articles

   Subscription
Subscribe now and receive free articles and updates instantly.
» Your name » Your Email

titles description    advance search
Published : June 19, 2006 | Author : Ali Roman
Category : General Blog | Total Views : 787 | Rating :

  
Due to lack of time, I could not implement sub category module, but I have implemented basic module for one of my client and updated cms.
 
I have updated the main Flax Article CMS, in this update I have made changed in functions.php and category.php file Here is the new function which I added in functions.php file
 
function get_sub_cats($cat_id) {
global $settings;
$g_arr = explode(",",SKIN_VARS); foreach($g_arr as $key => $val) global ${"$val"};

$cat_data = Array();
$res=query("select * from {$prefix}category WHERE cat_parent_id=$cat_id") or report();
if(mysql_num_rows($res)==0) echo "";

else {
for($i=0;$i

$row=fetch($res);
$cat_url = $settings['set_seo_onoff'] =='on'
? "$root_path/category/".plaintext($row['cat_name'])."-$row[cat_id]-1.html"
: "$root_path/category.php?cat_id=$row[cat_id]";
$cat_data []= "$row[cat_name]";
}
}
return implode(" | ",$cat_data);
 }
 
this retrieves all the sub-categories of any specific category ID you pass to the function, and displays it through category.php file, well I never planned sub-categories to be displayed like this, but since I am currentluy busy, I hope it will be a quick update for the people who have been waiting for it, sorry mates, but its good with versoin 1 I guess.




1 2 3 4 5
please rate this article     Poor
Excellent    
Most viewed articles in General Blog category

Swish user forums and online communities
CV Ali Roman
Recommended article management system cms
Hello :) ...my first post here
A bug in 2checkout passback variables
Most recent articles in General Blog category

Ryan's Internet Marketing Blog
Microsoft to buy Yahoo
Rapidshare Down or Shut Down
Accept Paypal in Pakistan and all other countries
CV Ali Roman

 Visitor's Comments !

there are no comments...


    Random Pick
My C.V for companies looking for remote programmer / designer. This was made for a specific company however, it lists some of my works completed so far.

    Statistics
» Total Articles
72
» Total Authors
96
» Total Views
116325
» Total categories
6

Delete cookies set by this site | Top   

Article Manager by Flaxweb
Copyright 2006 © Flax Article Manager v1.1