Results 1 to 8 of 8

Thread: Category Layout

  1. #1
    Join Date
    May 2004
    Location
    New Zealand
    Posts
    600

    Default Category Layout

    Is it possible to change the way that the categories display , such as setting it up as a addon/block ... so that when you upgrade you can still have it in your template settings and not have to adjust the PHP in category.class.php

    Im happy to play around with it, just not sure how to set it up so that it hooks or whatever the technical name for it is

    Cheers
    Ezy

  2. #2
    Join Date
    Nov 2008
    Posts
    92

    Default

    I don“t know if it help but in indexu administration at category edition you have a field called "Content" when you can add html code to each category.

  3. #3
    Join Date
    May 2004
    Location
    New Zealand
    Posts
    600

    Default

    Cheers mate, yeh its more around the code that generates how it displays, Ive altered it in that file before, however it makes it hard when you upgrade... so was wondering if we can set it up so the display code is seperate

  4. #4
    Join Date
    Mar 2009
    Posts
    143

    Default

    Hi can you tell me what display code you refer in category.class.php?

  5. #5
    Join Date
    May 2004
    Location
    New Zealand
    Posts
    600

    Default

    basically anything inside the table of categories.... like the code below, It would be cool to be able to the code for the table and cells etc externally from that php....


    if ($num_cats != 0) {
    $category = $this->header;
    $category .= "<table width=\"$this->cat_table_width\" cellspacing=\"$this->cat_cellspacing\">\n";
    $category .= "<tr>";

    $st_min = floor($num_cats / $this->number_of_columns);
    $st_max = ceil($num_cats / $this->number_of_columns);
    $st_burst = $num_cats % $this->number_of_columns;

    $k = 0;
    while ($k < $this->number_of_columns) {
    $width = 100 / $this->number_of_columns;
    $category .= "<td width=\"$width" . "%\" valign=\"top\">\n";

  6. #6
    Join Date
    May 2004
    Location
    New Zealand
    Posts
    600

    Default

    Any thoughts on how this can be done by the coders?

    If i have to ill go through and do it myself but just thought it would make more sense to be done by the coders so that everyone can have the feature

  7. #7
    Join Date
    Aug 2001
    Location
    Indonesia
    Posts
    3,732

    Default

    At the moment I have no better idea how to make it more simple. Category listing could be so simple or become complex. Everyone have different things in mind.

    You need to play with function Display() in category.class.php

    In future release I will allow designer to overwrite this function inside template. Bsically indexu will check a file, lets called 'komet/category_list.php', if the file is exist, it will use function Display() in this file, otherwise use in /lib/category.class.php

  8. #8
    Join Date
    Aug 2001
    Location
    Indonesia
    Posts
    3,732

    Default

    You still need basic knowledge of php

Similar Threads

  1. Layout
    By DGTALGOODIES in forum Help Wanted/Job Request
    Replies: 14
    Last Post: 04-02-2009, 01:47 AM
  2. Different Layout for Listings
    By Morphe in forum v5.x
    Replies: 8
    Last Post: 04-07-2008, 02:31 AM
  3. Layout issue : Help and advice please
    By mainman in forum v5.x
    Replies: 7
    Last Post: 03-10-2008, 12:44 AM
  4. layout problems
    By zupi in forum v5.x
    Replies: 13
    Last Post: 12-14-2007, 12:48 AM
  5. Changing Category Layout
    By xealinc in forum Blocks and Modification
    Replies: 4
    Last Post: 04-24-2007, 12:49 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •