{include file='header.tpl'}

		<div class="grid_full page_wrap">
			<legend><h1>Thank you for your purchase !</h1></legend>
			<div class="grid_half">
				<h3 style="margin: 0; padding: 0;">Your downloads</h3>
				<p><strong>Download Time Limit:</strong> 24 hours</p>
				<p>
					<strong>Time Left for Download:</strong>
				</p>
				<p>
					<span id="countdown">
						<span class="days">00</span>
						<span class="timeRefDays">days</span>
						<span class="hours">00</span>
						<span class="timeRefHours">hours</span>
						<span class="minutes">00</span>
						<span class="timeRefMinutes">minutes</span>
						<span class="seconds">00</span>
						<span class="timeRefSeconds">seconds</span>
					</span>
				</p>
				<p class="expired_text">We are sorry but your download has expired.</p>
			</div>
			<div class="grid_half">
				<p>Dear Alexandru,</p>
				<p>You have bought <strong>Something</strong> from <strong>Someone</strong></p>
				<p>Below are your purchase details:</p>
				<div class="well well-small">
					<p><strong>Product Name:</strong> {$down_prod.name}</p>
					<p><strong>Price:</strong> {$down_prod.price} {$down_prod.price_value}</p>
					<p><strong>Purchase Date:</strong> {$down_sales.date|date_format:"%D %T"}</p>
					<p><strong>Contact Person:</strong> {$down_prod.contact_name}</p>
					<p><strong>Support Email:</strong> {$down_prod.contact_email}</p>
				</div>	
			</div>
			<div class="clearfix"><br/></div><div class="clearfix"><br/></div><div class="clearfix"><br/></div>
			<div align="center"><a href="{$downid}?downnow=true" class="button" style="400px">Download</a></div>
			<div class="clearfix"><br/></div>
		</div>

		<hr />

		<!-- Testimonials -->
		<div id="testimonials">
			<h2>WHAT OUR CLIENTS SAY:</h2>
			<div class="testimonial">
				Elementum semper bibendum pulvinar elit tempus tellus nulla blandit libero quam, vitae justo !
				<small>John Dow - C.E.O @ Doejohn</small>
			</div>
		</div>
		
<script>
	$('.expired_text').hide();

			$("#countdown").countdown({
				date: '{$timetofinish|date_format:"%e %B %Y %H:%M:%S"|lower}', // add the countdown's end date (i.e. 3 november 2012 12:00:00)
				format: "on" // on (03:07:52) | off (3:7:52) - two_digits set to ON maintains layout consistency
			},
			function() { 
				// the code here will run when the countdown ends
				$("#countdown").html('Your download has expired !');
				$('.expired_text').show();
				
				$('.files_list li').each(function(index, value){
					var file_name = $(this).find('a').html();
					$(this).html(file_name);
				});
			});
			
		

</script>
		

{include file='footer.tpl'}