This file contains hidden or 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
| # ----------------------------------------------------------------- | |
| # .gitignore for WordPress | |
| # Bare Minimum Git | |
| # http://ironco.de/bare-minimum-git/ | |
| # ver 20150227 | |
| # | |
| # This file is tailored for a WordPress project | |
| # using the default directory structure | |
| # | |
| # This file specifies intentionally untracked files to ignore |
This file contains hidden or 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 | |
| // hide coupon field on cart page | |
| function hide_coupon_field_on_cart( $enabled ) { | |
| if ( is_cart() ) { | |
| $enabled = false; | |
| } | |
| return $enabled; |
This file contains hidden or 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 | |
| // Issue with showing VC shortcodes in search results | |
| // Strip out Visual Composer specific shortcodes | |
| add_filter('relevanssi_pre_excerpt_content', 'rlv_trim_vc_shortcodes'); | |
| function rlv_trim_vc_shortcodes($content) { | |
| $content = preg_replace('/\[\/?vc_.*?\]/', '', $content); | |
| return $content; | |
| } |
This file contains hidden or 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 | |
| // I did this simple hack on a private WordPress Multisite blog, to stop it | |
| // sending me emails every time I created a new blog. It's definitely overkill | |
| // to stop all emails, but unfortunately I couldn't find any hooks that let me | |
| // be more specific! (I didn't need any of the other emails - but you shouldn't | |
| // use this code if you do!) | |
| // I put the code in wp-config.php. You could create a plugin instead, or | |
| // putting it in your theme's functions.php might work (I haven't tested it). |
This file contains hidden or 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
| function test_wp_mail($args) | |
| { | |
| $debug = "<pre>" . var_export($args, true) . "</pre>"; | |
| wp_die($debug); | |
| } | |
| add_filter('wp_mail', 'test_wp_mail'); |
This file contains hidden or 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 NEW ADMIN USER TO WORDPRESS | |
| // ---------------------------------- | |
| // Put this file in your Wordpress root directory and run it from your browser. | |
| // Delete it when you're done. | |
| require_once('wp-blog-header.php'); | |
| require_once('wp-includes/registration.php'); | |
| // ---------------------------------------------------- |
This file contains hidden or 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 | |
| /* | |
| Plugin Name: Private Debug Log | |
| Description: Enable debug log to a private folder not accessible from the web | |
| Version: 0.0.1 | |
| Author: WebAware | |
| Author URI: http://www.webaware.com.au/ | |
| */ | |
| /* |
This file contains hidden or 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
| #301 Redirects for .htaccess | |
| #Redirect a single page: | |
| Redirect 301 /pagename.php http://www.domain.com/pagename.html | |
| #Redirect an entire site: | |
| Redirect 301 / http://www.domain.com/ | |
| #Redirect an entire site to a sub folder | |
| Redirect 301 / http://www.domain.com/subfolder/ |
This file contains hidden or 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 | |
| // Before VC Init | |
| add_action( 'vc_before_init', 'vc_before_init_actions' ); | |
| function vc_before_init_actions() { | |
| //.. Code from other Tutorials ..// | |
| // Require new custom Element |
This file contains hidden or 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
| # symlink to ~/.ssh/config | |
| Host github.com | |
| ControlMaster auto | |
| ControlPersist 120 | |
| Host * | |
| # Always use SSH2. | |
| Protocol 2 |