Skip to content

Instantly share code, notes, and snippets.

View ntwb's full-sized avatar
🏠
Working from home

Stephen Edgar ntwb

🏠
Working from home
View GitHub Profile
<?php
/**
* Plugin Name: bbPress Permalinks
* Plugin URI: http://korobochkin.com/
* Description: Change bbPress permalinks. ID number instead of topic slug. This links better than default if you have Cyrilic or other non english charackters in forum's and topic's slugs. forums/forum/FORUM_SLUG/ &rarr; forums/forum/ID/. forums/topic/TOPIC_SLUG/&rarr;forums/topic/ID/
* Author: Kolya Korobochkin
* Author URI: http://korobochkin.com/
* Version: 1.0.0
* Text Domain: bbpress_permalinks
* Domain Path: /languages/
@ntwb
ntwb / gist:2222965
Created March 28, 2012 02:24
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (PC)

Loosely ordered with the commands I use most towards the top. Sublime also offer full documentation.

Editing

Ctrl+C copy current line (if no selection)
Ctrl+X cut current line (if no selection)
Ctrl+⇧+K delete line
Ctrl+↩ insert line after
@ntwb
ntwb / Mingle.php
Last active December 11, 2015 02:58 — forked from anonymous/gist:4534163
<?php
/**
* Implementation of Mingle Forums converter.
*
* @since bbPress (r4689)
*/
class Mingle extends BBP_Converter_Base {
/**
@ntwb
ntwb / Vanilla.php
Last active December 11, 2015 17:18 — forked from brokentwig/Vanilla2.php
<?php
/**
* Implementation of Vanilla 2.0.18.1 Converter
*
* @since bbPress (r4717)
* @link Codex Docs http://codex.bbpress.org/import-forums/vanilla
*/
class Vanilla extends BBP_Converter_Base {
@ntwb
ntwb / 0_reuse_code.js
Created December 14, 2015 23:45
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
<?php
/**
* Implementation of Active Forums for DotNetNuke Converter
*
* @since bbPress (r4689)
*/
class DotNetNuke extends BBP_Converter_Base {
<?php
/**
* Implementation of miniBB Forum converter.
*
* @since bbPress (rXXXX)
* @link Codex Docs http://codex.bbpress.org/import-forums/minibb
*/
class miniBB extends BBP_Converter_Base {
@ntwb
ntwb / gist:229a1cbbbf77225a365e229c38ae699c
Created November 1, 2016 05:13 — forked from johnbillion/hierarchy.php
WordPress Template Hierarchy (as of WordPress 4.6)
<?php
/*
WordPress Template Hierarchy (as of WordPress 4.6)
is_404() ------------------------------------------------------------------------------------------------> 404.php
is_search() ---------------------------------------------------------------------------------------------> search.php
is_front_page() -----------------------------------------------------------------------------------------> front-page.php
is_home() -----------------------------------------------------------------------------------------------> home.php
@ntwb
ntwb / bbpress.scss
Last active September 30, 2018 10:41 — forked from cdils/bbpress.scss
This is quick, sassified version of the default bbPress stylesheet. I did not sassify the media queries at this point (I intend to re-work those as mobile-first for my project). Also note that I kept the original stylesheet organization. There's repition of some selectors that could be avoidded if the current organization was disregarded. :) As …
/**
* bbPress specific CSS
*
* @package bbPress
* @subpackage Theme
*/
/* =bbPress Style
-------------------------------------------------------------- */
@ntwb
ntwb / ExpressionEngine.php
Last active June 29, 2019 11:13 — forked from RickeyMessick/gist:780b857970a4bb72a79f
bbPress- Expression Engine Importer
<?php
/**
* ExpressionEngine converter base impoprter template for bbPress
*
* @since bbPress (rXXXX)
* @link Codex Docs http://codex.bbpress.org/import-forums/expression-engine
*/
class ExpressionEngine extends BBP_Converter_Base {