Skip to content

Instantly share code, notes, and snippets.

View jcamp's full-sized avatar

Jonathan jcamp

View GitHub Profile
@jcamp
jcamp / woocommerce.php
Created July 6, 2018 17:49 — forked from barbwiredmedia/woocommerce.php
Wordpress woocommerce thumbnails on product pages
// Woo commerce thumbnails beneath main product
add_filter ( 'woocommerce_product_thumbnails_columns', 'xx_thumb_cols' );
function xx_thumb_cols() {
return 4; // .last class applied to every 4th thumbnail
}
@jcamp
jcamp / woocommerce.php
Created July 6, 2018 17:48 — forked from barbwiredmedia/woocommerce.php
wordpress woocommerce out of stock
// Woo commerce change out of stock text
add_filter('woocommerce_get_availability', 'availability_filter_func');
function availability_filter_func($availability)
{
$availability['availability'] = str_ireplace('Out of stock', 'This item is currently out of stock. Please check back again at a later date.', $availability['availability']);
return $availability;
}
@jcamp
jcamp / Typography-page.html
Created July 6, 2018 17:48 — forked from barbwiredmedia/Typography-page.html
Typography page for WordPress to test WYSIWYG styling
<h1>Headline h1</h1>
<h2>Headline h2</h2>
<hr>
<h3>Headline h3</h3>
<h4 style="text-align: left;">Headline h4</h4>
<p><strong>Lorem</strong> ipsum dolor sit amet, <a href="http://google.com">consectetur adipiscing elit.</a> Nullam ac ante ut nibh laoreet rutrum nec vel enim. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. <del>Aenean</del> eget tellus quis lorem pharetra tincidunt non non odio. <em>Vestibulum</em> sed augue vel dolor accumsan iaculis.</p>
<h5>Headline h5</h5>
<h6>Headline h6</h6>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p>
<ul>
@jcamp
jcamp / admin-functions.php
Created July 6, 2018 17:46 — forked from barbwiredmedia/admin-functions.php
Edit and Hide Admin menu items admin_menu & admin_bar_menu. Also hide items from the item bar
function remove_acf_menu()
{
// provide a list of usernames who can edit custom field definitions here
$admins = array(
'admin',
'levy-admin',
'barb'
);
@jcamp
jcamp / RSS providers
Created August 15, 2017 10:42 — forked from X-Raym/RSS providers
Some hidden RSS feed for popular website
https://www.youtube.com/feeds/videos.xml?channel_id=CHANNELID
https://www.youtube.com/feeds/videos.xml?user=USERNAME
https://www.youtube.com/feeds/videos.xml?playlist_id=YOURPLAYLISTIDHERE
http://www.dailymotion.com/rss/user/USERNAME
@jcamp
jcamp / Git commands
Created May 9, 2017 13:52 — forked from orendzi/Git commands
Git commands in the sequence
/************************* SETTINGS *****************************/
p.s. git config can be changed in file .gitconfig or in console:
CONFIGURE GIT (optional)
1. Set your name
$ git config --global user.name <YOUR NAME>
2. Set your email
$ git config --global user.email <YOUR EMAIL ADDRESS>
@jcamp
jcamp / video-editors-opensource.md
Last active May 9, 2025 13:17
OpenSource Video Editors
@jcamp
jcamp / divi-desktop-menu.css
Last active March 1, 2020 10:49
DIVI Theme - Use mobile menu on desktop #divi
/* If you don’t want to clutter up your header bar with too many links, you can always choose to emulate what mobile
displays do: use a toggle to display a navigation menu.
Divi actually does this when being browsed from a mobile device, and the code below simply makes this toggle
button accessible when your site is being viewed from a PC. This way you can keep your header looking uncluttered.
*/
@media only screen and ( min-width:980px ) {
#et_mobile_nav_menu { display:block }
#top-menu-nav { display:none; }
@jcamp
jcamp / 0_reuse_code.js
Created May 4, 2017 10:28
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@jcamp
jcamp / wordpress-woocommerce-support
Created May 3, 2017 15:11
Wordpress theme support for WooCommerce gallery and zoom
If using the latest WooCommerce (as at [20170503]) add this to your theme to support the new zoom, slideshow and gallery.
functions.php
//---------------------------------------------------------------------
// WOOCOMMERCE
//---------------------------------------------------------------------
add_action( 'after_setup_theme', 'ss_setup' );