jqn -r markdown-table 'map(x => "## " + x.name + "\n\n" + markdownTable(x.columns.map(y => [y.name, y.type])) ) | join("\n\n")' < /tmp/stripe.json
id | varchar |
---|---|
business_name | varchar |
business_url | varchar |
<?php | |
// first query | |
$first_ids = get_posts( array( | |
'post_status'=> 'publish', | |
'orderby' => 'date', | |
'post_type'=> 'press', | |
'posts_per_page' => -1, | |
'order' => 'DESC', | |
)); |
<?php | |
// intended to be placed in short-description on the single product page | |
global $post, $product; | |
$id = $product->id; | |
$categories = get_the_terms( $product->get_id(), 'product_cat' ); | |
$firstlevelcategories = []; | |
$secondlevelcategories = []; | |
<?php | |
// this function can be used anyplace on your template and will show full size featured images of taxonomy terms, | |
// replace $term_id with the right ID and enjoy your life. | |
$term_id = 37; | |
$taxonomy = 'product_cat'; | |
// Get subcategories of the current category | |
$terms = get_terms([ |
<?php | |
// function can be placed in functions.php and then you can use on template files | |
// the following function, passing the ID of parent category | |
woocommerce_subcats_from_parentcat_by_ID($parent_cat_ID); | |
function woocommerce_subcats_from_parentcat_by_ID($parent_cat_ID) { | |
// custom parameters | |
$args = array( |
<?php | |
$books["978"] = "Jjaj"; | |
$books["978"] = "The Pepe"; | |
$books["978"] = "Jackie's Fables"; | |
$books["978"] = "Mahabhartazaa"; | |
?><html> | |
<head> |
/* | |
Make sure you execute the script in the right database! | |
- Delete all products - | |
Description: This script deletes all WooCommerce products | |
and their associations (categories/taxonomies and terms info) | |
*/ | |
DELETE relations.*, taxes.*, terms.* |
<?php | |
// Print term slug | |
$terms = get_the_terms( $post->ID , 'oil' ); | |
if ( $terms != null ){ | |
foreach( $terms as $term ) { | |
print $term->slug ; | |
unset($term); | |
} } | |
// Get term title |
// How To Remove Docker Containers, Images, Volumes, and Networks | |
// docker stop | |
docker stop $(docker ps -a -q) | |
docker rm $(docker ps -a -q) | |