#1 (permalink)  
Alt 29.08.2005, 14:18
 
Registriert seit: 15.08.2005
Beiträge: 5
Standard

Hallo,

Ich nutze keine Subkategorien, weshalb bei mir die Produkte direkt in den Kategorien liegen. Nun stellt sich die Kategorienbox aber wegen der fehlenden Subkategorien so dar:

link1

link2

link3


Ich w?rde gerne, schon allein um Platz zu sparen, die Zeilen direkt untereinander bringen;

link1
link2
link3


Hat da wer eine Idee?

Ich wei?, dass das in der xtc_show_category.inc.php eingestellt werden muss, wei? aber nicht, was ich da rausnehmen soll:

Code:
<?php
/* -----------------------------------------------------------------------------------------
  $Id: xtc_show_category.inc.php,v 1.1 2004/04/26 20:26:42 fanta2k Exp $

  XT-Commerce - community made shopping
  http://www.xt-commerce.com

  Copyright (c) 2003 XT-Commerce
  -----------------------------------------------------------------------------------------
  based on: 
  (c) 2000-2001 The Exchange Project (earlier name of osCommerce)
  (c) 2002-2003 osCommerce(categories.php,v 1.23 2002/11/12); www.oscommerce.com
  (c) 2003 nextcommerce (xtc_show_category.inc.php,v 1.4 2003/08/13); www.nextcommerce.org 

  Released under the GNU General Public License 
  ---------------------------------------------------------------------------------------*/

   function xtc_show_category($counter) {
  global $foo, $categories_string, $id;


  // image for first level
  $img_1='<img src="templates/'.CURRENT_TEMPLATE.'/img/icon_arrow.jpg" alt="" />';

  for ($a=0; $a<$foo[$counter]['level']; $a++) {

   if ($foo[$counter]['level']=='1') {
   $categories_string .= "-";
   }

   $categories_string .= "";

  }
  if ($foo[$counter]['level']=='') {
  if (strlen($categories_string)=='0') {
  $categories_string .='<table width="100%"><tr><td class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
  } else {
  $categories_string .='</td></tr></table><table width="100%"><tr><td class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
  }

  $categories_string .= $img_1;
  $categories_string .= '<b><a href="';
  } else {
  $categories_string .= '<a href="';
  }
  if ($foo[$counter]['parent'] == 0) {
   $cPath_new = 'cPath=' . $counter;
  } else {
   $cPath_new = 'cPath=' . $foo[$counter]['path'];
  }

  if (SEARCH_ENGINE_FRIENDLY_URLS == 'true') $cPath_new.='&category='.xtc_cleanName($foo[$counter]['name']);
  $categories_string .= xtc_href_link(FILENAME_DEFAULT, $cPath_new);
  $categories_string .= '">';

  if ( ($id) && (in_array($counter, $id)) ) {
   $categories_string .= '<b>';
  }

  // display category name
  $categories_string .= $foo[$counter]['name'];

  if ( ($id) && (in_array($counter, $id)) ) {
   $categories_string .= '</b>';
  }

  if (xtc_has_category_subcategories($counter)) {
   $categories_string .= '';
  }
  if ($foo[$counter]['level']=='') {
  $categories_string .= '</a></b>';
  } else {
  $categories_string .= '</a>';
  }

  if (SHOW_COUNTS == 'true') {
   $products_in_category = xtc_count_products_in_category($counter);
   if ($products_in_category > 0) {
    $categories_string .= '(' . $products_in_category . ')';
   }
  }

  $categories_string .= '<br />';

  if ($foo[$counter]['next_id']) {
    xtc_show_category($foo[$counter]['next_id']);
  } else {
    $categories_string .= '</td></tr></table>';
  }
 }

?>
W?re lieb, wenn mir jemand helfen k?nnte :-))

Dankesch?n!

Gru?
Melanie
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #2 (permalink)  
Alt 30.08.2005, 18:33
Erfahrener Benutzer
 
Registriert seit: 12.07.2005
Beiträge: 174
Standard

Gib mir mal den Link zu deinem Shop, viellecicht sehe ich da was.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #3 (permalink)  
Alt 30.08.2005, 20:44
Benutzerbild von polkhigh33
xt:C Supportmitarbeiter
 
Registriert seit: 26.10.2003
Ort: Hamburg
Beiträge: 6.862
Standard

im stylesheet die .moduleRow's anpassen, zb. mit height:...px;
__________________
dieser beitrag ist ohne gewähr und stellt nur meine meinung und keinesfalls eine rechtsberatung dar. im zweifelsfalle ist er ironisch gemeint.
.:netzdesign33.de:. | .:blog33.de:.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #4 (permalink)  
Alt 31.08.2005, 07:03
Erfahrener Benutzer
 
Registriert seit: 08.03.2005
Ort: Mußtopp
Beiträge: 638
Standard

Die Kategorien sind in Version 3 in Tabellen eingebettet. Diese verursachen ziemliche Abst?nde wenn man nicht mit den Stylesheets gegensteuert (s.o.). Versuch mal folgende modifizierte Version. Hier sind DIVs anstelle der Tabellen.

Gru?
Hen

Code:
 function xtc_show_category($counter) {
  global $foo, $categories_string, $id;


  // image for first level
  $img_1='<img src="templates/'.CURRENT_TEMPLATE.'/img/icon_arrow.jpg" alt="" />';

  for ($a=0; $a<$foo[$counter]['level']; $a++) {

   if ($foo[$counter]['level']=='1') {
   $categories_string .= "-";
   }

   $categories_string .= "";

  }
  if ($foo[$counter]['level']=='') {
//   if (strlen($categories_string)=='0') {
//    $categories_string .='<table width="100%"><tr><td class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
//   } else {
//    $categories_string .='</td></tr></table><table width="100%"><tr><td class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
//   }

   if (strlen($categories_string)=='0') {
    $categories_string .='<div class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
   } else {
    $categories_string .='</div><div class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)">';
   }

   $categories_string .= $img_1;
   $categories_string .= '<b><a href="';
  } else {
   $categories_string .= '<a href="';
  }
  if ($foo[$counter]['parent'] == 0) {
   $cPath_new = 'cPath=' . $counter;
  } else {
   $cPath_new = 'cPath=' . $foo[$counter]['path'];
  }

  if (SEARCH_ENGINE_FRIENDLY_URLS == 'true') $cPath_new.='&category='.xtc_cleanName($foo[$counter]['name']);
  $categories_string .= xtc_href_link(FILENAME_DEFAULT, $cPath_new);
  $categories_string .= '">';

  if ( ($id) && (in_array($counter, $id)) ) {
   $categories_string .= '<b>';
  }

  // display category name
  $categories_string .= $foo[$counter]['name'];

  if ( ($id) && (in_array($counter, $id)) ) {
   $categories_string .= '</b>';
  }

  if (xtc_has_category_subcategories($counter)) {
   $categories_string .= '';
  }
  if ($foo[$counter]['level']=='') {
  $categories_string .= '</a></b>';
  } else {
  $categories_string .= '</a>';
  }

  if (SHOW_COUNTS == 'true') {
   $products_in_category = xtc_count_products_in_category($counter);
   if ($products_in_category > 0) {
    $categories_string .= '(' . $products_in_category . ')';
   }
  }

  $categories_string .= '<br />';

  if ($foo[$counter]['next_id']) {
    xtc_show_category($foo[$counter]['next_id']);
  } else {
//    $categories_string .= '</td></tr></table>';
    $categories_string .= '</div>';
  }
 }
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
Antwort

Lesezeichen

Stichworte
kategorien, zeilenabstand

Themen-Optionen
Ansicht

Forumregeln
Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are aus
Pingbacks are aus
Refbacks are aus



Alle Zeitangaben in WEZ +1. Es ist jetzt 07:52 Uhr.

Copyright © 2011 xt:Commerce GmbH / xt:Commerce International Ltd. - All Rights Reserved

xt:Commerce is a SafeCharge brand