I want to send parameters from customer (name,e-mail and phone) and the product name to contact form with tpl an js. But the problem is how to get the phone value, i know only you can get phone like that in tpl {$customer.addresses [Address ID] .phone}. I know you can have multiple addresses, but i want to get first one, and of course to check if it exist. All this data i want to add is in product.tpl file. Any solution how to get first Address ID from customer?
Quote
<!--Contact Form Parameters-->
{if $customer.is_logged}
<p>Customer FirstName : {$customer.firstname}</p>
<p>Customer Name: {$customer.lastname}</p>
<p>Customer Email: {$[customer.email](https://customer.email)}</p>
<p>Customer ID: {$[customer.id](https://customer.id)}</p>
<p>Phone: ***~~{$customer.addresses\[7\].phone}~~***</p>
{/if}
{if $product.name}<p>Product: {$product.name}</p>{/if}
<!--/Contact Form Parameters-->