Instantly share code, notes, and snippets.

Alex Mustin alexmustin

View GitHub Profile
@alexmustin
alexmustin / file.sql
Last active Feb 8, 2019
SQL - Get emails for Users who have posted bbPress Topics or Replies
View file.sql
/* RUN THESE SEARCHES IN THE 'wp_posts' TABLE */
/* TOPICS */
SELECT DISTINCT user_email FROM wp_users,wp_posts WHERE ((wp_posts.post_author = wp_users.ID) AND (wp_posts.post_type = 'topic') AND (wp_posts.post_status = 'publish'))
/* REPLIES */
SELECT DISTINCT user_email FROM wp_users,wp_posts WHERE ((wp_posts.post_author = wp_users.ID) AND (wp_posts.post_type = 'reply') AND (wp_posts.post_status = 'publish'))
@alexmustin
alexmustin / custom-scripts.js
Last active Jan 2, 2019
Hello! Pro 1.x - Modified custom-scripts.js
View custom-scripts.js
/* // EQUAL HEIGHT BOXES // */
equalheight = function (container) {
var currentTallest = 0,
currentRowStart = 0,
rowDivs = new Array(),
$el,
topPosition = 0;
$(container).each(function () {
@alexmustin
alexmustin / functions.php
Created Dec 12, 2018
WooCommerce - Custom Reviews tab content
View functions.php
<?php
/**
* Customize product data tabs
*/
add_filter( 'woocommerce_product_tabs', 'woo_custom_reviews_tab', 98 );
function woo_custom_reviews_tab( $tabs ) {
$tabs['reviews']['callback'] = 'show_custom_reviews_tab_content'; // Custom description callback
@alexmustin
alexmustin / functions.php
Last active Dec 7, 2018
Genesis - Force Gutenberg Pages to be Full-Width
View functions.php
<?php
//* Force full-width-content layout for Gutenberg pages
add_filter( 'genesis_site_layout', 'setGutenbergPageLayout' );
function setGutenbergPageLayout(){
if ( function_exists( 'has_blocks' ) && has_blocks( get_the_ID() ) ) {
return 'full-width-content';
}
}
@alexmustin
alexmustin / text-widget.md
Last active Nov 9, 2018
Course Maker Documentation - Call to Action - Gravity Forms example
View text-widget.md

TITLE:

Start building your brand for free.

CONTENT:

[gravityform id="2" title="false" description="false"]

<p>Sign up and we'll email you a free PDF about Personal Branding. We respect your privacy, and never share your information.</p>

@alexmustin
alexmustin / genesis-enews-widget.md
Last active Nov 9, 2018
Course Maker Documentation - Call to Action - Genesis eNews Extended example
View genesis-enews-widget.md

TITLE: Start building your brand for free.

TEXT TO SHOW AFTER FORM:

<p>Sign up and we'll email you a free PDF about Personal Branding. We respect your privacy, and never share your information.</p>

FORM ACTION: #

View text-widget-1.md

TITLE: Build your brand, build your business.

CONTENT:

@alexmustin
alexmustin / widget.html
Created Nov 8, 2018
Course Make Documentation - WP Video Lightbox example
View widget.html
<a class="button" href="https://www.youtube.com/watch?v=YbRubFUmAtc" rel="wp-video-lightbox">Watch Video</a>
@alexmustin
alexmustin / html-widget.html
Created Nov 8, 2018
Course Maker Documentation - Second Chance Welcome widget example
View html-widget.html
Take a look at this example of the Course Maker theme by brandiD, built exclusively for the Genesis Framework. We like it so much, we're going to use it to market our own Personal Branding class.
<a class="button" href="https://www.youtube.com/watch?v=YbRubFUmAtc" rel="wp-video-lightbox">Watch Video</a>
@alexmustin
alexmustin / html-widget.html
Last active Nov 8, 2018
Course Maker Documentation - Home - Welcome widget example
View html-widget.html
<h1>Get to the Head of the Class</h1>
<p class="subhead">Lead your class with this clear, vibrant, easy-to-edit Genesis theme.</p>
<p>This theme is packed full of features and functionality to help you market your new course. The homepage layout will drive traffic to your site and engage users with your online course materials while communicating than you're an autority in your space, without actually saying that -- unless you want it to!</p>
<a href="https://thebrandidthemes.com/shop/" class="button">Buy the Theme</a>