Skip to content

Instantly share code, notes, and snippets.

View TwisterMc's full-sized avatar

Thomas McMahon TwisterMc

View GitHub Profile
@TwisterMc
TwisterMc / x
Created January 16, 2009 04:36
Simple blue and white Ubiquity skin.
/*
=skin=
@name Tranquil v1.0.2
@author Thomas McMahon
@homepage http://www.twistermc.com
@email [email protected]
@license MPL/LGPL/GPL
=/skin=
*/
/*
=skin=
@name Custom
@author You
@homepage http://www.yourpage.com
@email [email protected]
@license MPL/LGPL/GPL
=/skin=
@TwisterMc
TwisterMc / gist:10912379
Created April 16, 2014 17:43
Taller WordPress Admin Categories Box
// Make the categoires box bigger in the admin.
add_action('admin_head', 'admin_taller_categories_box');
function admin_taller_categories_box() {
echo '<style>
.categorydiv div.tabs-panel {
max-height: 500px;
}
</style>';
}
@TwisterMc
TwisterMc / export.php
Created June 11, 2014 12:50
Export WordPress Posts to CSV
<?php
/*
export.php - a script for outputting WordPress posts in CSV format.
Includes post ID, title, URL, tags and categories.
Tags and categories are semicolon seperated.
All commas are stripped from titles, tags and categories in order to keep the CSV format.
Drop this file in the main WordPress directory; next to wp-config.php.
Remove when done using.
*/
@TwisterMc
TwisterMc / gist:72c8213e65b17e5c11a3
Created December 10, 2014 14:34
Things Mac Bookmarklet Updated
javascript:window.location='things:add?title='+encodeURIComponent(document.title)+'&notes='+encodeURIComponent(document.URL)
@TwisterMc
TwisterMc / FacebookMedia
Last active August 29, 2015 14:18
Integrate Facebook Photos into WordPress' Media Manager
// Proof of Concept only.
// Incomplete Code
function facebook_media_upload_tab_name( $tabs ) {
$newtab = array( 'tab_slug' => 'Insert from Facebook' );
return array_merge( $tabs, $newtab );
}
add_filter( 'media_upload_tabs', 'facebook_media_upload_tab_name' );
/**
* Create custom WordPress Role 'Webmaster' with all Administrator capabilities.
* Remember to delete this code when done as it's only needed once.
*/
$customRoleName = 'Webmaster';
$customRoleID = 'webmaster'; // No spaces, all lowercase
$createCustomRole = add_role(
$customRoleID,
@TwisterMc
TwisterMc / bbLogin.php
Last active December 15, 2016 16:51
Use the Logo from BeaverBiulder's settings for the WordPress login screen.
<?php
/**
* Custom Login
* Pulls the logo from the BeverBuilder's customizer settings.
*/
function bbLogo_login_logo() {
$LogoImage = get_theme_mod( 'fl-logo-image-retina');
if ( !$LogoImage ) {
$LogoImage = get_theme_mod( 'fl-logo-image');
@TwisterMc
TwisterMc / beaverbuilder-jump-links.js
Created February 16, 2017 21:41
Make jump links between pages work better when there is a fixed header.
@TwisterMc
TwisterMc / bb-ddm.css
Last active October 28, 2017 17:05
Beaver Builder Drop Down Menu Indicators
/* add the drop down indicator to parent */
.fl-page-header .menu-item-has-children a:after {content: " ▾"; }
/* remove drop down indicator from children */
.fl-page-header .sub-menu a:after {content: ""; }