Skip to content

Instantly share code, notes, and snippets.

View frankschrijvers's full-sized avatar

WPStudio frankschrijvers

View GitHub Profile
curl -LO https://github.com/restic/restic/releases/download/v0.9.5/restic_0.9.5_linux_amd64.bz2
.page-contact .site-footer {
background-color: #000;
color: #fff;
}
@frankschrijvers
frankschrijvers / page-slug-body-class.php
Last active June 20, 2019 09:24
Add Page Slug as Body Class
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
add_filter( 'body_class', 'wps_add_slug_body_class' );
/**
* Add Page Slug as Body Class.
*/
function wps_add_slug_body_class( $classes ) {
global $post;
@frankschrijvers
frankschrijvers / woocommerce-show-payment-method.php
Created May 7, 2019 08:44
Add Payment Method Column to Admin Orders
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
add_filter( 'manage_edit-shop_order_columns', 'wps_add_payment_method_column', 20 );
/**
* Add payment method column
*/
function wps_add_payment_method_column( $columns ) {
$new_columns = array();
@frankschrijvers
frankschrijvers / style.css
Created July 18, 2017 15:06
Styling for more input fields opt in widget hanvana theme
.enews-widget input[type=email],
.enews-widget input[type=text] {
border: 1px solid #eee;
max-width: calc(38% - 20px);
float: left;
}
@frankschrijvers
frankschrijvers / text.html
Created July 12, 2017 08:31
button textwidget
<a class="button" href="#">read more</a>
@frankschrijvers
frankschrijvers / functions.php
Last active July 17, 2021 04:07
Set WooCommerce product button text to productname
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
add_filter( 'woocommerce_product_single_add_to_cart_text', 'wps_custom_cart_button_text' );
/**
* Set product button text to productname
*/
function wps_custom_cart_button_text() {
global $product;
@frankschrijvers
frankschrijvers / textwidget.html
Last active February 17, 2017 15:16
textwidget.html Accent Pro theme
Don't miss the new seasons 2017 look book!<div class="button"><a href="#">learn more</a></div>
@frankschrijvers
frankschrijvers / banner-widget.html
Last active October 6, 2016 10:39
Add banner to widget area
<a href="https://www.wpstud.io"><img src="place the url of your banner here"></a>
@frankschrijvers
frankschrijvers / fuctions.php
Created September 19, 2016 09:03
Add more categories
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
case 'clothing':
return __('Order your Clothes', 'your_theme_text_domain' );
break;
case 'hoodies':
return __('buy your Hoodie', 'your_theme_text_domain' );
break;