Skip to content

Instantly share code, notes, and snippets.

View n7studios's full-sized avatar

Tim Carr n7studios

View GitHub Profile
@n7studios
n7studios / frontend.js
Last active August 29, 2015 14:02
WordPress: Fade in last sidebar widget
jQuery(document).ready(function($) {
/**
* Configuration
* The container for your sidebar e.g. aside, #sidebar etc.
*/
var sidebarElement = $('div#secondary');
// End config
// Check if the sidebar exists
if ($(sidebarElement).length > 0) {
@n7studios
n7studios / soliloquy-count-slide-transition.php
Last active August 29, 2015 14:06
Soliloquy: Redirect after nth slide
<?php
add_action( 'soliloquy_api_after_transition', 'count_slide_transition' );
function count_slide_transition( $data ) {
ob_start();
?>
count++;
if (count == 10) {
// Do redirect
}
@n7studios
n7studios / soliloquy-featured-content-custom-field.php
Last active August 29, 2015 14:06
Soliloquy Featured Content: Add ACF Custom Field to Caption
@n7studios
n7studios / envira-append-lightbox.php
Created September 22, 2014 09:57
Envira - Append to Lightbox
<?php
/**
* Plugin Name: Envira Hooks
* Plugin URI: http://enviragallery.com
* Description: Testing ground for hooks and filters
* Author: Tim Carr
* Author URI: http://thomasgriffinmedia.com
* Version: 1.0.0
* Text Domain: envira-hooks
* Domain Path: languages
@n7studios
n7studios / custom-tinymce-plugin-icon.js
Last active September 3, 2018 08:03
Custom TinyMCE Dashicon
(function() {
tinymce.PluginManager.add('custom_tinymce_plugin', function(editor,url) {
editor.addButton('custom_tinymce_plugin', {
title: 'Custom TinyMCE Plugin',
icon: 'bold',
onclick: function() {
editor.insertContent('Button clicked!');
}
})
});
@n7studios
n7studios / envira-hooks.php
Created October 28, 2014 14:08
Envira Gallery: Open links in a new browser tab
<?php
/**
* Plugin Name: Envira Hooks
* Plugin URI: http://enviragallery.com
* Description: Testing ground for hooks and filters
* Author: Tim Carr
* Author URI: http://thomasgriffinmedia.com
* Version: 1.0.0
* Text Domain: envira-hooks
* Domain Path: languages
@n7studios
n7studios / soliloquy-featured-content-continue-reading-link.php
Last active August 29, 2015 14:08
Soliloquy - Featured Content Addon - Change "Continue Reading" Link
@n7studios
n7studios / custom.css
Created November 4, 2014 11:38
Soliloquy - soliloquywp.com homepage style button
.soliloquy-container .soliloquy-caption {
top: 0;
width: 100%;
}
.soliloquy-container .soliloquy-caption .soliloquy-caption-inside {
vertical-align: middle;
text-align: center;
background: none;
}
.soliloquy-container .soliloquy-caption .soliloquy-caption-inside h1 {
@n7studios
n7studios / soliloquy-dynamic-start-slide.php
Created November 5, 2014 12:54
Soliloquy - Dynamic Start Slide Position
<?php
/**
* Plugin Name: Soliloquy - Dynamic Start Slide
* Plugin URI: http://soliloquywp.com
* Version: 1.0
* Author: Tim Carr
* Author URI: http://www.n7studios.co.uk
* Description: If ?sol_slide=X exists in a Permalink that contains a Soliloquy slider, the slider will start on the given index number (X)
*/
@n7studios
n7studios / soliloquy-exclude-from-search.php
Last active September 3, 2015 15:54
Soliloquy - Exclude from Search
<?php
/**
* Plugin Name: Soliloquy - Exclude from Search
* Plugin URI: http://soliloquywp.com
* Version: 1.0
* Author: Tim Carr
* Author URI: http://www.n7studios.co.uk
* Description: Exclude Soliloquy Sliders from Search Results
*/