This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
component accessors=true hint='Order bean' { | |
property totalAmount type='Money'; | |
property consumer type='Consumer'; | |
property billing type='Contact'; | |
property shipping type='Contact'; | |
property description type='string'; | |
property items type='array'; | |
property discounts type='array'; | |
property merchant type='Merchant'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Pre-populate Woocommerce checkout fields | |
*/ | |
add_filter('woocommerce_checkout_get_value', function($input, $key ) { | |
global $current_user; | |
switch ($key) : | |
case 'billing_first_name': | |
case 'shipping_first_name': | |
return $current_user->first_name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>jQuery Validate</title> | |
<!-- Include jquery & jquery.validate --> | |
<script type="text/javascript"> | |
$(document).ready(function () { | |
$('form.validate').validate(); | |
}); | |
</script> |