[TYPO3-shop] Fatal error

Franz Holzinger franz at fholzinger.com
Sun Jan 13 07:56:09 CET 2008


Juan Pablo Villaverde a écrit :
> if (!is_object($order)) {
>  include_once (PATH_BE_ttproducts.'model/class.tx_ttproducts_order.php');
>  // order
>  $order = &t3lib_div::getUserObj('tx_ttproducts_order');
>  $order->init(
>   $this->pibase,
>   $this->cnf,
>   $this->tt_products,
>   $this->tt_products_articles,
>   $this->tt_products_cat,
>   $this->basket,
>   $this->conf['useArticles']
>  );
> }
> 
> Hope that helps! :-)

It would be better to pass the $order object as a parameter for the
payment script:

lib/class.tx_ttproducts_paymentshipping.php:
function includeHandleScript($handleScript, &$confScript, $order,
$activity, &$bFinalize)	{

control/class.tx_ttproducts_control.php:
function processPayment(&$content, &$bFinalize, &$order, &$basketView,
&$info, &$card, &$account)	{
	global $TSFE;

	$handleScript =
$TSFE->tmpl->getFileName($this->basket->basketExtra['payment.']['handleScript']);
	$this->basket->getCalculatedSums();
	if ($handleScript)	{
		$content.= $this->paymentshipping->includeHandleScript($handleScript,
$this->basket->basketExtra['payment.']['handleScript.'], $order,
$this->conf['paymentActivity'], $bFinalize);
	} else if

in the DIBS script you must change all ...->order to $order



More information about the TYPO3-project-tt-products mailing list