Direct link to ordersDelivery (with products)

sampsu

No avatar

2007-02-18 13:31

Is it possible to have some sort off direct link to ordersDelivery page where suppose to be some products ?

Can i save ordersDelivery page where is 1 product. And when i give direct adress to it, people can just fill thei information and make the order.

» Quick.Cart v2.x

treewood (OpenSolution)

Avatar: treewood

2007-02-19 08:36

sampsu - But You want basket with allready defined products and after redirect to ordersDelivery page or You want if someone add product to basket to redirect to ordersDelivery?

sampsu

No avatar

2007-02-19 20:06

I want basket where is allready defined products / product and after redirect to ordersDelivery page.

But it should not affect the normal shopping in my store.

Is that possible anyway ?

Thank for help in advance

treewood (OpenSolution)

Avatar: treewood

2007-02-20 08:05

sampsu - interesting problem. try do that:
1. edit actions_client/orders.php and find this this:

elseif( $sOption == 'del' ){

2. before add this code

<?php
elseif( $sOption == 'defined' ){
  
$aProductsToAdd[] = Array( 2);
  
$aProductsToAdd[] = Array( 3);
  
$iCount count$aProductsToAdd );
  for( 
$i 0$i $iCount$i++ ){
    
$aReturn dbCheckOrderProduct$iOrder$aProductsToAdd[$i][0] );
    if( !isset( 
$aReturn ) )
      
addOrderProduct$aProductsToAdd[$i][0], $aProductsToAdd[$i][1], $iOrder );
  } 
// end for
  
header'Location: '.$_SERVER['PHP_SELF'].'?p=ordersDelivery' );
  exit;
}
?>


3. You need to define $aProductsToAdd variables. As You see You have 2 products allready defined. Array( 2, 1 ); this means that product with ID 2 will be added with quantity 1. Array( 3, 2 ); means product with ID 3 will be added with quantity 2.
4. You should change link in templates/page.tpl to basket from ?p=ordersBasket to ?p=ordersBasket&sOption=defined

Works? Please tell me that it works ... it takes me lot time :/

Back to top
about us | contact