Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $basket_html .= '<form action="'. $sess->url( SECUREURL."index.php?page=".$next_page."&checkout_last_step=".$current_stage) .'" method="post" name="adminForm">
- <input type="hidden" name="option" value="com_virtuemart" />
- <input type="hidden" name="Itemid" value="'. $Itemid .'" />
- <input type="hidden" name="user_id" value="'. $auth['user_id'] .'" />
- <input type="hidden" name="page" value="'. $next_page .'" />
- <input type="hidden" name="func" value="checkoutProcess" />
- <input type="hidden" name="zone_qty" value="'. $zone_qty .'" />
- <input type="hidden" name="ship_to_info_id" value="'. $ship_to_info_id .'" />
- <input type="hidden" name="shipping_rate_id" value="'. urlencode($shipping_rate_id) .'" />
- <input type="hidden" name="payment_method_id" value="'. $payment_method_id .'" />
- <input type="hidden" name="checkout_last_step" value="'. $current_stage .'" />';
- $theme->set( 'basket_html', $basket_html );
- // CHECK_OUT_GET_SHIPPING_ADDR
- // Lets the user pick or add an alternative Shipping Address
- if( in_array('CHECK_OUT_GET_SHIPPING_ADDR', $checkout_steps[$current_stage]) ) {
- echo '<a name="CHECK_OUT_GET_SHIPPING_ADDR"></a>';
- echo $theme->fetch( 'checkout/get_shipping_address.tpl.php');
- $theme->set('basket_html', '');
- }
- // CHECK_OUT_GET_SHIPPING_METHOD
- // Let the user pick a shipping method
- if( in_array('CHECK_OUT_GET_SHIPPING_METHOD', $checkout_steps[$current_stage]) ) {
- echo '<a name="CHECK_OUT_GET_SHIPPING_METHOD"></a>';
- echo $theme->fetch( 'checkout/get_shipping_method.tpl.php');
- $theme->set('basket_html', '');
- }
- // -CHECK_OUT_GET_PAYMENT_METHOD
- // let the user choose a payment method
- if( in_array('CHECK_OUT_GET_PAYMENT_METHOD', $checkout_steps[$current_stage]) ) {
- echo '<a name="CHECK_OUT_GET_PAYMENT_METHOD"></a>';
- if(!empty( $paypal_api_payment_method_id ) && $paypalActive)
- {
- echo $theme->fetch('checkout/get_payment_method_paypal_ex.tpl.php');
- }
- else
- {
- echo $theme->fetch( 'checkout/get_payment_method.tpl.php');
- }
- $theme->set('basket_html', '');
- }
- // -CHECK_OUT_GET_FINAL_CONFIRMATION
- // shows a total summary including all payments, taxes, fees etc.
- if( in_array('CHECK_OUT_GET_FINAL_CONFIRMATION', $checkout_steps[$current_stage]) ) {
- echo '<a name="CHECK_OUT_GET_FINAL_CONFIRMATION"></a>';
- // Now let the user confirm
- echo $theme->fetch( 'checkout/get_final_confirmation.tpl.php');
- $theme->set('basket_html', '');
- }
- ?>
- <br /><?php
- foreach( $checkout_steps[$current_stage] as $this_step ) {
- echo '<input type="hidden" name="checkout_this_step[]" value="'.$this_step.'" />';
- }
- // Set Dynamic Page Title: "Checkout: Step x of x"
- $ii = 0;
- for( $i = 1; $i < 5; $i++ ) {
- if( isset( $checkout_steps[$i] ) ) {
- $ii += 1;
- if( in_array($this_step, $checkout_steps[$i] ) ) {
- $mainframe->setPageTitle( sprintf( $VM_LANG->_('VM_CHECKOUT_TITLE_TAG'), $ii, count($checkout_steps) ));
- break;
- }
- }
- }
- if( !in_array('CHECK_OUT_GET_FINAL_CONFIRMATION', $checkout_steps[$current_stage]) ) {
- ?>
- <div align="center">
- <input type="submit" class="button" name="formSubmit" value="<?php echo $VM_LANG->_('PHPSHOP_CHECKOUT_NEXT');?> >>" />
- </div>
- <?php
- }
- // Close the Checkout Form, which was opened in the first checkout template using the variable $basket_html
- echo '</form>';
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement