Zen Cart Logo
Forums / General Questions / Trouble getting custom shipping module options to pass to payment page

Trouble getting custom shipping module options to pass to payment page

Locked

Views: 777

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
18 Aug 2010, 6:17 PM
#1
scubaguy avatar

scubaguy

New Zenner

Join Date:
Apr 2005
Posts:
2
Plugin Contributions:
0

Trouble getting custom shipping module options to pass to payment page

I created a custom shipping module that allows me to set flat shipping rates per category and zone. Everything works great except that no matter what option I select the only the first shipping option in the list is passed to the payment checkout page. Here is the loop code. Does anyone know how I can get this to work? Thanks in advance. Using Zencart 1.39e

The $count_poles variable is a check to see if the shipping method is allowed for the category and $check_zone verifies that it is valid for the customer's geo zone.

foreach $zone /* more code */ {

if ($category == $count_poles && $check_zone == $order->delivery['zone_id']) {

				$methods[] = array(

				'id' => $this->code.'_0'.$i,
				'title' => $shipping_title,

				'cost' => $shipping_cost

				);

			}

		}



		$this->quotes = array(

			'id' => $this->code,

			'module' => $this->title,

			'methods' => $methods,

		);

$this->quotes['methods'] = $methods;
18 Aug 2010, 9:51 PM
#2
scubaguy avatar

scubaguy

New Zenner

Join Date:
Apr 2005
Posts:
2
Plugin Contributions:
0

Re: Trouble getting custom shipping module options to pass to payment page

I did some checking and for some reason I haven't been able to figure out the shipping method data is not being saved to the $_SESSION and it is defaulting to the first method in the $quotes array. Any ideas?