<div class="table-responsive table-grey">
<table>

<tr>
<td width="20%"><strong>{$LANG.orderproduct}</strong></td>
<td>{$groupname} - {$productname}{if $domain} ({$domain}){/if}</td>
</tr>

<tr>
</tr>

</table>
</div>

{if $overdueinvoice}

			<div class="notice notice-error">
				<div class="inside">
					<p>{$LANG.upgrade_error}</p>
				</div>
			</div>

<p>{$LANG.upgrade_overdue1}</p>

<p>{$LANG.upgrade_overdue2}</p>

<p><input type="button" value="{$LANG.clientareabacklink}" onclick="window.location='clientarea.php?action=productdetails&id={$id}'" class="button1 color1"></p>

{else}

{if $type eq "package"}

<p>{$LANG.upgradechoosepackage}</p>

 	<div class="feildset">
		
			<div class="col1"> 

{foreach key=num item=upgradepackage from=$upgradepackages}

<tr class="{cycle values="orderrow1,orderrow2"}"><td align="center">
<form method="post" action="{$smarty.server.PHP_SELF}">
<input type="hidden" name="step" value="2">
<input type="hidden" name="type" value="{$type}">
<input type="hidden" name="id" value="{$id}">
<input type="hidden" name="pid" value="{$upgradepackage.pid}">	

<h2>Upgrade {$upgradepackage.groupname} - {$upgradepackage.name}</h2>

<p>{$upgradepackage.description}</p>


{if $upgradepackage.pricing.type eq "free"}


	<div>
		{$LANG.orderfree}
	</div>	
	
	<input type="hidden" name="billingcycle" value="free">
	
	{elseif $upgradepackage.pricing.type eq "onetime"}

	<div>
		<label>
			<span>Payment term</span>
			{$LANG.orderpaymenttermonetime}
		</label>
	</div>

	<input type="hidden" name="billingcycle" value="onetime">

	{elseif $upgradepackage.pricing.type eq "recurring"}
	
		<div>
			<label>
				<span>{$LANG.upgrade_term}</span>
				<select name="billingcycle">
{if $upgradepackage.pricing.monthly}<option value="monthly">{$upgradepackage.pricing.monthly}</option>{/if}
{if $upgradepackage.pricing.quarterly}<option value="quarterly">{$upgradepackage.pricing.quarterly}</option>{/if}
{if $upgradepackage.pricing.semiannually}<option value="semiannually">{$upgradepackage.pricing.semiannually}</option>{/if}
{if $upgradepackage.pricing.annually}<option value="annually">{$upgradepackage.pricing.annually}</option>{/if}
{if $upgradepackage.pricing.biennially}<option value="biennially">{$upgradepackage.pricing.biennially}</option>{/if}
{if $upgradepackage.pricing.triennially}<option value="triennially">{$upgradepackage.pricing.triennially}</option>{/if}
</select>
			</label>
		</div>


{/if}

</div>

<p class="center margintop20"><input type="submit" value="{$LANG.ordercontinuebutton}" class="button1 color2" /></p>

</form>

</div>

{/foreach}


{elseif $type eq "configoptions"}

<p>{$LANG.upgradechooseconfigoptions}</p>

{if $errormessage}
			<div class="notice notice-error">
				<div class="inside">
					<p>{$errormessage}</p>
				</div>
			</div>
{/if}

<form method="post" action="{$smarty.server.PHP_SELF}">
<input type="hidden" name="step" value="2">
<input type="hidden" name="type" value="{$type}">
<input type="hidden" name="id" value="{$id}">





<div class="table-responsive table-grey">
<table>
<tr><th></th><th>{$LANG.upgradecurrentconfig}</th><th></th><th>{$LANG.upgradenewconfig}</th></tr>
{foreach key=num item=configoption from=$configoptions}
<tr class="carttableproduct"><td><b>{$configoption.optionname}</b></td><td align="center">
{if $configoption.optiontype eq 1 || $configoption.optiontype eq 2}
{$configoption.selectedname}
{elseif $configoption.optiontype eq 3}
{if $configoption.selectedqty}{$LANG.yes}{else}{$LANG.no}{/if}
{elseif $configoption.optiontype eq 4}
{$configoption.selectedqty} x {$configoption.options.0.name}
{/if}
</td><td align="center">=></td><td align="center">
{if $configoption.optiontype eq 1 || $configoption.optiontype eq 2}
<select name="configoption[{$configoption.id}]">{foreach key=num item=option from=$configoption.options}
{if $option.selected}<option value="{$option.id}" selected>{$LANG.upgradenochange}</option>{else}<option value="{$option.id}">{$option.nameonly} {$currencysymbol}{$option.price} {$currency}{/if}</option>
{/foreach}</select>
{elseif $configoption.optiontype eq 3}
<input type="checkbox" name="configoption[{$configoption.id}]" value="1"{if $configoption.selectedqty} checked{/if}> {$configoption.options.0.name}
{elseif $configoption.optiontype eq 4}
<input type="text" name="configoption[{$configoption.id}]" value="{$configoption.selectedqty}" size="5"> x {$configoption.options.0.name}{/if}</td></tr>
{/foreach}
</table>
</div>

<p class="center"><input type="submit" value="{$LANG.ordercontinuebutton}" class="button1 color2" /></p>

</form>

{/if}

{/if}