#1 (permalink)  
Alt 09.06.2004, 21:09
Benutzerbild von Buggyboy
Erfahrener Benutzer
 
Registriert seit: 06.09.2003
Beiträge: 353
Standard

Hallo!

F?r den OSC gab es mal eine Constribution: All_Prods.php

Damit werden alle Produkte des Shops aufglistet und als Link dargestellt.
K?nnte vielleicht jemand den Code umbauen f?r XTC oder ist das nicht erlaubt?

Hier ist schonmal der Code von der mir letzt bekannten Version:

Code:
<?php
/*
 $Id: allprods.php,v 1.5 2002/09/29 1

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2002 osCommerce

 Released under the GNU General Public License
*/

 require('includes/application_top.php');

// Set number of columns in listing
define ('NR_COLUMNS', 2);
//
?>
<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<title><?php echo TITLE ?></title>
<base href="<?php echo (getenv('HTTPS') == 'on' ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>">
<link rel="stylesheet" type="text/css" href="stylesheet.css">
</head>
<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0">
<!#header //-->
<?php require(DIR_WS_INCLUDES . 'header.php'); ?>
<!#header_eof //-->

<!#body //-->
<table border="0" width="100%" cellspacing="3" cellpadding="3">
 <tr>
  <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">
<!#left_navigation //-->
<?php require(DIR_WS_INCLUDES . 'column_left.php'); ?>
<!#left_navigation_eof //-->
  </table></td>
<!#body_text //-->
  <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
   <tr>
    <td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0">
     <tr>
      <td class="pageHeading">All Products</td>
      <td align="right"></td>
     </tr>
    </table></td>
   </tr>
   <tr>
    <td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
   </tr>
   <tr>
    <td><table border="0" width="100%" cellspacing="0" cellpadding="2">
       <?php
  $languages_query = tep_db_query("select languages_id, name, code, image, directory from " . TABLE_LANGUAGES . " order by sort_order");
  while ($languages = tep_db_fetch_array($languages_query)) {
  $languages_array[] = array('id' 	=> $languages['languages_id'],
       'name' => $languages['name'],
                   'code' => $languages['code'],
                   'image' => $languages['image'],
                      'directory'	=> $languages['directory']);
  }
      for ($i=0; $i<sizeof($languages_array); $i++) {  
       $this_language_id = $languages_array[$i]['id'];
  $this_language_name = $languages_array[$i]['name'];
  $this_language_code = $languages_array[$i]['code'];
  $this_language_image = $languages_array[$i]['image'];
  $this_language_directory = $languages_array[$i]['directory'];
  echo " <tr>\n";
  echo "  <td class=main>\n";
  echo "   " . tep_image(DIR_WS_LANGUAGES . $this_language_directory . '/images/' . $this_language_image, $this_language_name) . "<b>" . $this_language_name . "</b>";
  echo "  </td>\n";
  echo " </tr>\n";
  echo " <tr>\n";
       $products_query = tep_db_query("SELECT p.products_id, pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id AND p.products_status = 1 AND pd.language_id = $this_language_id ORDER BY pd.products_name");
  $products_array = array();
  while($products = tep_db_fetch_array($products_query)) {
    $products_array[] = array('id'  => $products['products_id'],
        'name' => $products['products_name']);
  }
  for ($j=0; $j<NR_COLUMNS; $j++) {
  	echo "  <td class=main>\n";
  	for ($k=$j; $k<sizeof($products_array); $k+=NR_COLUMNS) {
   $this_products_id  = $products_array[$k]['id'];
   $this_products_name = $products_array[$k]['name'];
   print("   <a href=\"" . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $this_products_id . '&language=' . $this_language_code, 'NONSSL', false) . "\">" . $this_products_name . "</a><br>\n");
  	}
  	echo "  </td>\n";
  }
    echo " </tr>\n";
 	}
?>
      </td>
     </tr>
    </table></td>
   </tr>
   <tr>
  <td align="right" class="main"><br><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT, '', 'NONSSL') . '">' . tep_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td>
   </tr>
  </table></td>
<!#body_text_eof //-->
  <td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">
<!#right_navigation //-->
<?php require(DIR_WS_INCLUDES . 'column_right.php'); ?>
<!#right_navigation_eof //-->
  </table></td>
 </tr>
</table>
<!#body_eof //-->

<!#footer //-->
<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>
<!#footer_eof //-->
<br>
</body>
</html>
<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
Besteht da ?berhaupt Interesse dran?

Bis denne...
peter
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #2 (permalink)  
Alt 10.06.2004, 09:26
 
Registriert seit: 13.10.2003
Beiträge: 57
Standard

Das umsetzten ist kein Problem. Die frage ist nur ob sich das lohnt.

Denn wenn man z.B. sehr viele Artikel hat, dann hat man auch eine dementsprechende ladezeit.

Wir haben zur zeit 1000 Artikel in unserem Shop und bei fertigstellung fast 10000 Artikel.

Dann kannste dir ja umrechnen wie die Ladezeit aussieht.

Wenn Ihr wollt, bau ich euch gerne mal sowas.

Vieleicht ?ber mehrere Seite verteilt dann oder so.

Mfg
Sascha
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #3 (permalink)  
Alt 21.06.2004, 21:17
 
Registriert seit: 13.10.2003
Beiträge: 57
Standard

Meintest du das so ?

http://www.gebaeudereiniger-einkauf.de/all...ll_products.php

Mfg
Sascha
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #4 (permalink)  
Alt 22.06.2004, 05:25
Benutzerbild von Buggyboy
Erfahrener Benutzer
 
Registriert seit: 06.09.2003
Beiträge: 353
Standard

Moin Sascha!

Genauso meinte ich das.

Bis denne...
Peter
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #5 (permalink)  
Alt 22.06.2004, 12:30
 
Registriert seit: 13.10.2003
Beiträge: 57
Standard

Hallo,
kannste dir hier runterladen.

http://www.xt-commerce.com/modules/mydownl...p?cid=36&lid=89

Mfg
Sascha
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #6 (permalink)  
Alt 22.06.2004, 18:13
Benutzerbild von Buggyboy
Erfahrener Benutzer
 
Registriert seit: 06.09.2003
Beiträge: 353
Standard

Hallo Sascha!

Vielen Dank.
Werde es heute Abend mal einbauen... ;-}

Bis denne...
Peter
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #7 (permalink)  
Alt 22.06.2004, 18:50
Benutzerbild von Buggyboy
Erfahrener Benutzer
 
Registriert seit: 06.09.2003
Beiträge: 353
Standard

Zitat:
Originally posted by Buggyboy@Jun 22 2004, 18:13 PM
Hallo Sascha!

Vielen Dank.
Werde es heute Abend mal einbauen... ;-}

Bis denne...
Peter

?dit: Alles eingebaut. Funzt wunderbar.

Ich habe dann noch eine kleine Design?nderung vorgenommen.

Im Link habe ich noch folgendes eingef?gt:
class="topNavigation"
Damit wird der Link halt so angezeigt wie alle anderen auch.

Sah nicht so gut aus: Alle anderen hellblau und Alle Produkte in schwarz ;-}

Respekt. Cooles Teil... ;-}
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #8 (permalink)  
Alt 22.06.2004, 19:08
 
Registriert seit: 13.10.2003
Beiträge: 57
Standard

Danke Danke.

Das h?rt man gern :bounce:
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #9 (permalink)  
Alt 22.06.2004, 19:55
Benutzerbild von Buggyboy
Erfahrener Benutzer
 
Registriert seit: 06.09.2003
Beiträge: 353
Standard

Hi!

Da ich nicht wu?te wo und wie man im Content Manager diese Datei mit einbinden kann, habe ich die "Alle Produkte" .php manuell in die Box Information mit eingebaut.

Geht das ?berhaupt, das man in die Content-Boxen Dateien aus dem Hauptverzeichniss eintragen kann? Oder m??en die immer im Ordner content/media liegen?
Dann m??en die doch auch sicher noch angepa?t werden, oder?

naja. Jedenfalls funzt es so auch.

In der Datei box_information.html im Verzeichniss: templates/deintemplate/boxes folgenden Code ersetzt:
Code:
<td align="left" class="boxText"><font size="1" face="Verdana, Arial, Helvetica, sans-serif">{$BOX_CONTENT}<br>

<a href="all_products.php">Alle Produkte</a>

</font></td>
Hier hab ich dann die class Zuweisung wieder rausgenommen, da die Links in der Box in schwarz sind ;-}

Bis denne...
Peter
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
  #10 (permalink)  
Alt 24.06.2004, 08:19
 
Registriert seit: 09.03.2004
Beiträge: 30
Standard

Zitat:
Originally posted by Buggyboy@Jun 9 2004, 21:09 PM
Hallo!

F?r den OSC gab es mal eine Constribution: All_Prods.php

Damit werden alle Produkte des Shops aufglistet und als Link dargestellt.
K?nnte vielleicht jemand den Code umbauen f?r XTC oder ist das nicht erlaubt?

Hier ist schonmal der Code von der mir letzt bekannten Version:

Code:
<?php
/*
 ?$Id: allprods.php,v 1.5 2002/09/29 1

 ?osCommerce, Open Source E-Commerce Solutions
 ?http://www.oscommerce.com

 ?Copyright (c) 2002 osCommerce

 ?Released under the GNU General Public License
*/

 ?require('includes/application_top.php');

// Set number of columns in listing
define ('NR_COLUMNS', 2);
//
?>
<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<title><?php echo TITLE ?></title>
<base href="<?php echo (getenv('HTTPS') == 'on' ? HTTPS_SERVER : HTTP_SERVER) . DIR_WS_CATALOG; ?>">
<link rel="stylesheet" type="text/css" href="stylesheet.css">
</head>
<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0">
<!#header //-->
<?php require(DIR_WS_INCLUDES . 'header.php'); ?>
<!#header_eof //-->

<!#body //-->
<table border="0" width="100%" cellspacing="3" cellpadding="3">
 ?<tr>
 ? ?<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">
<!#left_navigation //-->
<?php require(DIR_WS_INCLUDES . 'column_left.php'); ?>
<!#left_navigation_eof //-->
 ? ?</table></td>
<!#body_text //-->
 ? ?<td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">
 ? ? ?<tr>
 ? ? ? ?<td width="100%"><table border="0" width="100%" cellspacing="0" cellpadding="0">
 ? ? ? ? ?<tr>
 ? ? ? ? ? ?<td class="pageHeading">All Products</td>
 ? ? ? ? ? ?<td align="right"></td>
 ? ? ? ? ?</tr>
 ? ? ? ?</table></td>
 ? ? ?</tr>
 ? ? ?<tr>
 ? ? ? ?<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>
 ? ? ?</tr>
 ? ? ?<tr>
 ? ? ? ?<td><table border="0" width="100%" cellspacing="0" cellpadding="2">
 ? ? ? ? ? ? <?php
 ? ?$languages_query = tep_db_query("select languages_id, name, code, image, directory from " . TABLE_LANGUAGES . " order by sort_order");
 ? ?while ($languages = tep_db_fetch_array($languages_query)) {
 ? ?$languages_array[] = array('id' ?	=> $languages['languages_id'],
 ? ? ? ? ? ? 'name' ?=> $languages['name'],
 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'code' ?=> $languages['code'],
 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?'image' ?=> $languages['image'],
 ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? 'directory'	=> $languages['directory']);
 ? ?}
 ? ? ? ? ? ?for ($i=0; $i<sizeof($languages_array); $i++) { ? ?
 ? ? ? ? ? ? ?$this_language_id = $languages_array[$i]['id'];
 ? ?$this_language_name = $languages_array[$i]['name'];
 ? ?$this_language_code = $languages_array[$i]['code'];
 ? ?$this_language_image = $languages_array[$i]['image'];
 ? ?$this_language_directory = $languages_array[$i]['directory'];
 ? ?echo " <tr>\n";
 ? ?echo " ? <td class=main>\n";
 ? ?echo " ? ? " . tep_image(DIR_WS_LANGUAGES . $this_language_directory . '/images/' . $this_language_image, $this_language_name) . "<b>" . $this_language_name . "</b>";
 ? ?echo " ? </td>\n";
 ? ?echo " </tr>\n";
 ? ?echo " <tr>\n";
 ? ? ? ? ? ? ?$products_query = tep_db_query("SELECT p.products_id, pd.products_name FROM " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd WHERE p.products_id = pd.products_id AND p.products_status = 1 AND pd.language_id = $this_language_id ORDER BY pd.products_name");
 ? ?$products_array = array();
 ? ?while($products = tep_db_fetch_array($products_query)) {
 ? ? ? $products_array[] = array('id' ? => $products['products_id'],
 ? ? ? ? ? ? ? 'name' => $products['products_name']);
 ? ?}
 ? ?for ($j=0; $j<NR_COLUMNS; $j++) {
 ? ?	echo " ? <td class=main>\n";
 ? ?	for ($k=$j; $k<sizeof($products_array); $k+=NR_COLUMNS) {
 ? ? ?$this_products_id ? = $products_array[$k]['id'];
 ? ? ?$this_products_name = $products_array[$k]['name'];
 ? ? ?print(" ? ? <a href=\"" . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $this_products_id . '&language=' . $this_language_code, 'NONSSL', false) . "\">" . $this_products_name . "</a><br>\n");
 ? ?	}
 ? ?	echo " ? </td>\n";
 ? ?}
 ? ? ? echo " </tr>\n";
 ?	}
?>
 ? ? ? ? ? ?</td>
 ? ? ? ? ?</tr>
 ? ? ? ?</table></td>
 ? ? ?</tr>
 ? ? ?<tr>
 ? ?<td align="right" class="main"><br><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT, '', 'NONSSL') . '">' . tep_image_button('button_continue.gif', IMAGE_BUTTON_CONTINUE) . '</a>'; ?></td>
 ? ? ?</tr>
 ? ?</table></td>
<!#body_text_eof //-->
 ? ?<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">
<!#right_navigation //-->
<?php require(DIR_WS_INCLUDES . 'column_right.php'); ?>
<!#right_navigation_eof //-->
 ? ?</table></td>
 ?</tr>
</table>
<!#body_eof //-->

<!#footer //-->
<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>
<!#footer_eof //-->
<br>
</body>
</html>
<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
Besteht da ?berhaupt Interesse dran?

Bis denne...
peter
Hallo Sascha,
ein tolles Modul und habe es auch gleich auf meine Startseite installiert.
Und vielen Dank f?r Deine M?he.
Was mir allerdings aufgefallen ist, dass Titel, die mit der Bezeichnung "XIV..." anfangen, nicht mit angezeigt werden. Vielleicht k?nnte man - wenn es Dir nicht zu viel Arbeit macht - diesen kleinen Fehler noch beheben.

Beste Gr?sse PetraK
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Wong this Post!
Mit Zitat antworten
Antwort

Lesezeichen

Stichworte
auflisten, produkte, shops

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 18:55 Uhr.

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

xt:Commerce is a SafeCharge brand