<form id="wc_lost_license_form" method="post">

	<div class="form-row form-row-first">
		<p>Please tell us the email address used during the purchase. Your license along with the order receipt will be sent by email.</p>
		<p>If your email address has changed, please contact us.</p>
	</div>

	<div class="form-row form-row-last">
		<noscript><p class="woocommerce-error">Javascript must be enabled to use this form.</p></noscript>
		<p><label for="wc_email">Your email address:</label> <input type="text" class="input-text" id="wc_email" name="wc_email" /></p>
		<p><input type="submit" class="button-alt" name="wc_lost_license_btn" id="wc_lost_license_btn" value="Email License Keys" /></p>
	</div>

	<div class="clear"></div>
</form>

<script type="text/javascript">

	jQuery(function(){
		jQuery('#wc_lost_license_form').on( 'submit', function(){

			$form = jQuery('#wc_lost_license_form');
			$form.block({message: null, overlayCSS: { background: '#fff', opacity: 0.6 }});

			if ( ! $form.hasClass('loading') ) {

				$form.addClass('loading');

				jQuery('.woocommerce-error, .woocommerce-message').fadeOut('fast', function(){
					jQuery(this).remove();
				});

				var data = {
					action: 			'woocommerce_lost_license',
					security: 			'e9794bc2fe',
					email: 				jQuery('input[name="wc_email"]').val()
				};

				jQuery.post( "/wp-admin/admin-ajax.php", data, function( response ) {

					$form.removeClass('loading');
					$form.unblock();

					if ( response.success ) {

						$form.prepend( '<div class="woocommerce-message">' + response.message + '</div>' ).fadeIn();

					} else {
						if ( response.success === false ) {
							$form.prepend( '<div class="woocommerce-error">' + response.message + '</div>' ).fadeIn();
						} else {
							$form.prepend( '<div class="woocommerce-error">' + 'Error processing request' + '</div>' ).fadeIn();
						}
					}

				}, "json" );
			}

			return false;
		});
	});
</script>
{"id":161,"date":"2018-06-06T10:53:11","date_gmt":"2018-06-06T10:53:11","guid":{"rendered":"http:\/\/127.0.0.1\/wordpress\/lost-license\/"},"modified":"2020-04-27T11:21:30","modified_gmt":"2020-04-27T11:21:30","slug":"lost-license","status":"publish","type":"page","link":"https:\/\/scan-score.com\/en\/lost-license\/","title":{"rendered":"Lost License"},"content":{"rendered":"\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_acf_changed":false,"_seopress_robots_primary_cat":"","_seopress_titles_title":"","_seopress_titles_desc":"","_seopress_robots_index":"yes","_seopress_analysis_target_kw":"","site-sidebar-layout":"default","site-content-layout":"plain-container","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"default","adv-header-id-meta":"","stick-header-meta":"default","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":"","tve_updated_post":"","tve_custom_css":"","tve_user_custom_css":"","tve_globals":{},"tcb2_ready":1,"tcb_editor_enabled":0,"tve_landing_page":"","_tve_header":"","_tve_footer":""},"class_list":["post-161","page","type-page","status-publish","hentry"],"acf":[],"_links":{"self":[{"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/pages\/161","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/comments?post=161"}],"version-history":[{"count":0,"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/pages\/161\/revisions"}],"wp:attachment":[{"href":"https:\/\/scan-score.com\/en\/wp-json\/wp\/v2\/media?parent=161"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}