Hallo,
Ich habe hier ein script welches in oscommerce für den Ausdruck eines Paketscheins zuständig. Dieses Script soll noch erweitert werden das an der mit xxxx gekentzeichneten Stelle der custumer_name aus der Tabelle orders angezeigt wird. Kriege das irgendwie nicht richtig hin. Hier ist der Code:
require('includes/application_top.php');
require(DIR_WS_CLASSES . 'currencies.php');
$currencies = new currencies();
$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);
$orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . tep_db_input($oID) . "'");
include(DIR_WS_CLASSES . 'order.php');
$order = new order($oID);
?>
<!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; ?>">
<link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
</head>
<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF">
<!-- body_text //-->
<table width="100%" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> </td>
</tr>
</table>
<table width="896" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="263" height="20"> </td>
<td class="main" align="left" height="20" width="633">
<?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, ' ', '<br>'); ?>
</td>
</tr>
</table>
<table width="100%" height="17" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="100%" id="AutoNumber1">
<tr>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
</tr>
</table>
</td>
</tr>
</table>
<table width="896" height="55" border="0" cellspacing="0" cellpadding="0">
<?php
$i = sizeof($order->totals);
$i = $i -1;
?>
<tr>
<td width="312" height="14"></td>
<td align="left" width="584" height="14" colspan="2">
</tr>
<tr>
<td width="312" height="5">
<p align="right"><font face="Arial"><font size="2">EUR</font></font><font size="2">
</font> </td>
<td align="left" width="584" height="5" colspan="2"><b> </b>
<?php echo $order->totals[$i]['text']; ?> XXXX custumer_name soll hier hin!
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="584" height="5" colspan="2">
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="584" height="5" colspan="2">
</tr>
<tr>
<td width="312" height="48"> </td>
<td align="left" width="584" height="48" colspan="2"> </tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">text</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">text</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">textr</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
</tr>
</table>
<!-- body_text_eof //-->
<br>
</body>
</html><?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
Danke für Eure Hilfe.
Grüsse
Ralph
Ich habe hier ein script welches in oscommerce für den Ausdruck eines Paketscheins zuständig. Dieses Script soll noch erweitert werden das an der mit xxxx gekentzeichneten Stelle der custumer_name aus der Tabelle orders angezeigt wird. Kriege das irgendwie nicht richtig hin. Hier ist der Code:
require('includes/application_top.php');
require(DIR_WS_CLASSES . 'currencies.php');
$currencies = new currencies();
$oID = tep_db_prepare_input($HTTP_GET_VARS['oID']);
$orders_query = tep_db_query("select orders_id from " . TABLE_ORDERS . " where orders_id = '" . tep_db_input($oID) . "'");
include(DIR_WS_CLASSES . 'order.php');
$order = new order($oID);
?>
<!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; ?>">
<link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
</head>
<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF">
<!-- body_text //-->
<table width="100%" height="50" border="0" cellspacing="0" cellpadding="0">
<tr>
<td> </td>
</tr>
</table>
<table width="896" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="263" height="20"> </td>
<td class="main" align="left" height="20" width="633">
<?php echo tep_address_format($order->delivery['format_id'], $order->delivery, 1, ' ', '<br>'); ?>
</td>
</tr>
</table>
<table width="100%" height="17" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" width="100%" id="AutoNumber1">
<tr>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
<td width="10%"> </td>
</tr>
</table>
</td>
</tr>
</table>
<table width="896" height="55" border="0" cellspacing="0" cellpadding="0">
<?php
$i = sizeof($order->totals);
$i = $i -1;
?>
<tr>
<td width="312" height="14"></td>
<td align="left" width="584" height="14" colspan="2">
</tr>
<tr>
<td width="312" height="5">
<p align="right"><font face="Arial"><font size="2">EUR</font></font><font size="2">
</font> </td>
<td align="left" width="584" height="5" colspan="2"><b> </b>
<?php echo $order->totals[$i]['text']; ?> XXXX custumer_name soll hier hin!
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="584" height="5" colspan="2">
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="584" height="5" colspan="2">
</tr>
<tr>
<td width="312" height="48"> </td>
<td align="left" width="584" height="48" colspan="2"> </tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">text</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">text</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
<font face="Arial" style="font-size: 9pt">textr</font></tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
</tr>
<tr>
<td width="312" height="5"></td>
<td align="left" width="30" height="5">
</tr>
<td align="left" width="554" height="5">
</tr>
</table>
<!-- body_text_eof //-->
<br>
</body>
</html><?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
Danke für Eure Hilfe.
Grüsse
Ralph
Kommentar