I hereby claim:
- I am norcross on github.
- I am norcross (https://keybase.io/norcross) on keybase.
- I have a public key whose fingerprint is E1F6 278F F814 8561 0D2E 3A5F 2AA5 6935 BA0B 15C8
To claim this, I am signing this object:
<?php | |
/** set up redirects from old structure */ | |
function aly_post_redirects() { | |
if ( ! is_user_logged_in() ) | |
return; | |
if ( is_404() ) : | |
$slug = $_SERVER['REQUEST_URI']; |
<?php | |
// extra check for price that can create a sortable value | |
if ( isset( $property_details['_listing_price'] ) && ! empty( $property_details['_listing_price'] ) ) { | |
// strip anything other than a decimal | |
$price_sortable = preg_replace( '/[^0-9\.]/', '', $property_details['_listing_price'] ); | |
// update the value with a floatval check | |
update_post_meta( $post_id, '_listing_price_sortable', floatval( $price_sortable ) ); | |
} else { | |
delete_post_meta( $post_id, '_listing_price_sortable' ); | |
} |
<?php | |
add_filter ( 'posts_search', 'rkv_search_by_title_only', 500, 2 ); | |
/** | |
* restrict search query to only compare titles | |
* @param string $search search query passed by user | |
* @param mixed $wp_query global query from WP being modified | |
* @return mixed search results | |
*/ | |
function rkv_search_by_title_only( $search, $wp_query ) { |
I hereby claim:
To claim this, I am signing this object:
<?php | |
header('Content-type: text/plain'); | |
$versions = array( | |
'1', | |
'1.0', | |
'1.01', | |
'1.1', | |
'1.1.0', | |
'1.1.1b', |
<?php | |
$type = 'my-post-type'; | |
$tax = 'my-taxonomy'; | |
$args = array( | |
'post_type' => $type, | |
'nopaging' => true, | |
'tax_query' => array( |
$( 'div#postbox-container-1' ).each(function() { | |
// set the float box | |
var pubBox = $( this ).find( 'div#submitdiv' ); | |
// get our sizes and offsets | |
var pubWth = ( pubBox ).width(); | |
var offTop = $( 'div#postbox-container-1' ).offset().top; | |
var offRgt = ( $( window ).width() - ( pubBox.offset().left + pubBox.outerWidth() ) ); |
<?php | |
add_action( 'wp_before_admin_bar_render', 'rkv_node_ids_to_toolbar' ); | |
/** | |
* run throught all available nodes in the global wp_admin_bar | |
* and create a multi level dropdown | |
* | |
* used for when you need to remove one (or more) | |
*/ |