This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Sends user to the start page on first activation, as well as each time the | |
* plugin is upgraded to a new version | |
* | |
* @access public | |
* @since 1.1 | |
* @return void | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Manging of version numbers when plugin is activated | |
*/ | |
function MYPLUGIN_install() { | |
// Add Upgraded From Option | |
$current_version = get_option( MYPLUGIN_NAMESPACE . '_version' ); | |
if ( $current_version ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Add our links to the plugin page, these show under the plugin in the table view. | |
* | |
* @param $links(array) The links coming in as an array | |
* @param $current_plugin_file(string) This is the "plugin basename", i.e., my-plugin/plugin.php | |
*/ | |
function my_plugin_action_links( $links, $current_plugin_file ){ | |
if ( $current_plugin_file == 'my-plugin/plugin.php' ){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fastcgi_cache_path /home/foo/site.com/cache levels=1:2 keys_zone=WORDPRESS:100m inactive=60m; | |
fastcgi_cache_key "$scheme$request_method$host$request_uri"; | |
server { | |
# also use www here | |
server_name site.com; | |
access_log /home/foo/site.com/logs/access.log; | |
error_log /home/foo/site.com/logs/error.log; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Block direct EDD downloads for WordPress Networking | |
location ~ ^/wp-content/uploads/sites/(.*)/edd/(.*?)\.zip$ { | |
rewrite / permanent; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
case ( is_tax( $my_taxonomies ) ): | |
global $wp_query; | |
if ( in_array( $wp_query->query_vars['taxonomy'], $my_taxonomies ) ) { | |
foreach ( $my_taxonomies as $taxonomy ) { | |
load_template( MY_PLUGIN_DIR . 'theme/archive-' . $k['type'] . '.php' ); | |
// load_template( MY_PLUGIN_DIR . 'theme/taxonomy-' . $my_taxonomies. '.php' ); | |
} | |
} | |
exit; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ ${PWD##*/} == task-tracker ]; then | |
echo `git notes show` | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[core] | |
repositoryformatversion = 0 | |
filemode = true | |
bare = false | |
logallrefupdates = true | |
[color] | |
ui = auto | |
interactive = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
foreach( $this->post_type as $wtf ) { | |
$my_cpt = get_post_types( array( 'name' => $wtf['type']), 'objects' ); | |
if ( is_tax( $wtf['taxonomies'] ) ) { | |
global $wp_query; | |
if ( in_array( $wp_query->query_vars['taxonomy'], $wtf['taxonomies'] ) ) { | |
if ( file_exists( MY_PLUGIN_DIR . 'theme/custom/' . $wtf['type'] . '-taxonomy.php' ) ) { | |
load_template( MY_PLUGIN_DIR . 'theme/custom/' . $wtf['type'] . '-taxonomy.php' ); | |
} elseif ( file_exists( MY_PLUGIN_DIR . 'theme/default/taxonomy.php' ) ) { | |
load_template( MY_PLUGIN_DIR . 'theme/default/taxonomy.php' ); |
OlderNewer