Quickly disable all plugins in WordPress.
This plugin needs to go into the wp-content/mu-plugins/ directory. Provided you have SSH access to the server where WordPress lives, you can do this:
cd $SITE_ROOT/wp-content/mu-plugins| <?php | |
| $odd_or_even = 'even'; | |
| $args = array( | |
| 'cat' => 1, | |
| 'posts_per_page' => 2, | |
| 'order' => 'DESC' | |
| ); | |
| $query = new WP_Query( $args ); | |
| if ( $query->have_posts() ) : while ( $query->have_posts() ) : $query->the_post(); |
| <?php | |
| /** | |
| * WordPress Query Comprehensive Reference | |
| * Compiled by luetkemj - luetkemj.com | |
| * | |
| * CODEX: http://codex.wordpress.org/Class_Reference/WP_Query | |
| * Source: http://core.trac.wordpress.org/browser/tags/3.3.1/wp-includes/query.php | |
| */ | |
| $args = array( |
| #301 Redirect Local Images to Live | |
| RedirectMatch 301 ^/wp-content/uploads/(.*) http://livewebsite.com/wp-content/uploads/$1 |
| ################################################################ | |
| # Example configuration file for nginx | |
| # | |
| # To add a new local WordPress domain to your environment, copy | |
| # this file using a filename that matches the domain you wish to | |
| # setup. For example - mylocaldomain.com.conf would be an ideal | |
| # filename for http://mylocaldomain.com | |
| # | |
| # Once copied, you will need to modify two settings in the server | |
| # configuration provided: |
| /** | |
| * fixMSWord | |
| * | |
| * Replace ascii chars with utf8. Note there are ascii characters that don't | |
| * correctly map and will be replaced by spaces. | |
| * | |
| * Updated 7-15-2015 by Jay Wood to encode lower end items into HTML entity counterparts. | |
| * | |
| * @author Robin Cafolla,Jay Wood | |
| * @date 2013-03-22 |
| // Create an object in the global scope, pass in window, jQuery, and the global object into the anonymous function. | |
| window.myObject = ( function( window, $, myObject ) { | |
| // Create our object, properties, and functions. | |
| myObject = { | |
| window: $( window ), // Remove if you don't need it, makes your object smaller. | |
| // Access variables using myObject.options | |
| options { |
| ( function( $ ) { | |
| // Create a jQuery Object. | |
| $.fn.myObject = function() { | |
| var target = this; // Store the target element in this variable (jQuery stuff). | |
| // Our stuff. | |
| this.object = { | |
| /** |
https://www.virendrachandak.com/techtalk/php-isset-vs-empty-vs-is_null/
http://www.zomeoff.com/php-fast-way-to-determine-a-key-elements-existance-in-an-array/
$people = array(
'one' => 'Eric', // true
'two' => '', // false
'three' => null, // false