Zen Cart Logo
Forums / Setting Up Categories, Products, Attributes / Attributes not being emailed. All I get is 'Array'

Attributes not being emailed. All I get is 'Array'

Locked

Views: 532

Results 1 to 2 of 2
This thread is locked. New replies are disabled.
21 Apr 2010, 5:02 PM
#1
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Attributes not being emailed. All I get is 'Array'

I inherited a zencart mod and can't figure out what's wrong. The customer selects a product and an attribute (model#). This is then sent to another form that they complete. When they submit the form, the product and the attribute should be included in the email sent.

At this time, only the product is coming through. The attribute just says "array." The interesting part is, when I delete the line that prints the attribute, the products_options_names will print out. So I know that both the product and the products_options_names are working. The attribute is the only thing that is not working right.

Here's what I believe to be the significant code. This is the page that has the form, so the attribute has already be passed to this page, I can see it on the page as rendered in the browser.

//Begin Adding of New features
//$productsimage = $product['productsImage'];
$productsname = $product['productsName'];
$attributes = $product['attributes'];
$products_options_name = $value['products_options_name'];

$arr_product_list[] = "<strong>Product Name:</strong> $productsname <br />";
$arr_product_list[] .= "<strong>Attributes:</strong> $attributes <br />";
$arr_product_list[] .= "<strong>Products Options Name:</strong> $products_options_name <br />";
$arr_product_list[] .= "---------------------------------------------------------------";

//End Adding of New features

} // end foreach ($productArray as $product)
?>

Above this is the following code:

<?php echo $product['attributeHiddenField']; if (isset($product['attributes']) && is_array($product['attributes'])) { echo '<div class="cartAttribsList">'; echo '<ul>'; reset($product['attributes']); foreach ($product['attributes'] as $option => $value) { ?>

Any help would be appreciated.

27 Apr 2010, 4:04 PM
#2
spaz_tic avatar

spaz_tic

New Zenner

Join Date:
Nov 2009
Posts:
18
Plugin Contributions:
0

Re: Attributes not being emailed. All I get is 'Array'

Never mind. Got it working myself.