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
jQuery(document).ready(function($){ | |
if(location.hash){ | |
if($(location.hash)){ | |
setTimeout(function(){ | |
var targetTop = $('#content').offset().top; | |
targetTop -= $('#header').height() + $('#nav').height() - 23; | |
$('body,html').scrollTop(targetTop); |
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 | |
/** | |
* The template for displaying Search Results pages. | |
* | |
* @since alterna 1.0 | |
*/ | |
get_header(); ?> | |
<?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 get_header(); ?> | |
<?php | |
$number_of_feature_posts = 1; | |
$number_of_secondary_posts = 8; | |
$paged = (get_query_var('paged')) ? get_query_var('paged') : 1; | |
$how_many_secondary_posts_past = ($number_of_secondary_posts * ($paged - 1)); | |
$off = $number_of_feature_posts + (($paged > 1) ? $how_many_secondary_posts_past : 0); | |
?> |
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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
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 | |
/** | |
* The template for displaying Search Results pages | |
* | |
* @package WordPress | |
* @subpackage Twenty_Twelve | |
* @since Twenty Twelve 1.0 | |
*/ | |
get_header(); |
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 | |
function my_searchwp_extra_metadata( $extra_meta, $post_being_indexed ) { | |
// index the author country | |
$author_country = get_field('my_countries', $post_being_indexed->post_author ); | |
// it's stored as an array so let's get the actual text | |
$author_country = is_array( $author_country ) && count( $author_country ) ? implode( ' ', $author_country ) : ''; | |
if ( ! empty ( $author_country ) ) { | |
$extra_meta['my_author_meta_country'] = $author_country; |
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 | |
/* Template Name: SearchWP Supplemental Search Engine Postcode Search */ | |
global $post; | |
// retrieve our search query if applicable | |
$query = isset( $_REQUEST['postcode'] ) ? sanitize_text_field( $_REQUEST['postcode'] ) : ''; | |
// if there was a space in the search, grab the first part |
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 | |
/** | |
* The template used for generating blog template Format 1 List | |
* | |
* @package WordPress | |
* @subpackage ASI Themes | |
* @since IOA Framework V1 | |
*/ | |
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
[2015-20-05 6:30:11][notice][555cc4a378e56] | |
[2015-20-05 6:30:11][notice][555cc4a378e56] ========== INIT 555cc4a378e56 2.5.4 ========== | |
[2015-20-05 6:30:11][notice][555cc4a378e56] | |
[2015-20-05 6:30:11][notice][555cc4a378e56] checkForMainQuery(): It is the main query | |
[2015-20-05 6:30:11][notice][555cc4a378e56] | |
[2015-20-05 6:30:11][notice][555cc4a378e56] ========== END 555cc4a378e56 ========== | |
[2015-20-05 6:30:11][notice][555cc4a378e56] | |
[2015-20-05 6:30:12][notice][555cc4a482e1d] | |
[2015-20-05 6:30:12][notice][555cc4a482e1d] ========== INIT 555cc4a482e1d 2.5.4 ========== |
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 to your theme's functions.php | |
add_filter( 'searchwp_indexed_post_types', 'my_searchwp_indexed_post_types' ); | |
add_filter( 'searchwp_engine_settings_default', 'my_searchwp_engine_settings_default', 10, 2 ); | |
function my_searchwp_indexed_post_types( $post_types ) { | |
if ( ! in_array( 'attachment', $post_types ) ) { | |
$post_types[] = 'attachment'; | |
} |
OlderNewer