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 | |
/* Register custom post types on the 'init' hook. */ | |
add_action( 'init', 'my_register_post_types' ); | |
/** | |
* Registers post types needed by the plugin. | |
* | |
* @since 0.1.0 | |
* @access public |
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
// 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 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
add_filter( 'genesis_attr_content', 'custom_attributes_content' ); | |
/** | |
* Add the class needed for FacetWP to main element. | |
* | |
* Context: Posts page, all Archives and Search results page. | |
* | |
* @author Sridhar Katakam | |
* @link http://sridharkatakam.com/facetwp-genesis/ | |
*/ | |
function custom_attributes_content( $attributes ) { |
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
<a title="Click To Call (07) 3103 3642" href="tel:+6131033642">(07) 3103 3642</a> |
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
<a title="Click to call" href="tel:+61234567891"><img src="http://www.domain.tld/image-file.png" alt="Clickable Phone Number Example" width="1000" height="238" /></a |
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
// NB search for domain.com in this file and change it to your live domain. | |
jQuery(function($) | |
{ | |
"use strict"; | |
$(document).ready(function() | |
{ | |
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 | |
/* | |
* Google Phone Tracking For Google Adwords In A Genesis Child Theme. | |
* | |
* Step 1. | |
* Add this snippet into the Functions File, then ... | |
* | |
* Step 2. | |
* Replace all instance of the phone number (07) 1234 5678 ans =671712345678 |
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
# BEGIN Force HTTPS - Place after WordPress Permalink block | |
<IfModule mod_rewrite.c> | |
RewriteEngine on | |
RewriteCond %{HTTPS} !=on [NC] | |
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L] | |
</IfModule> | |
# END Force HTTPS |
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
# BEGIN HSTS Support | |
# To ensure all urls are redirected to SSL | |
Header add Strict-Transport-Security: "max-age=15768000" | |
# END HSTS Support |
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
# BEGIN Add Secure and httpOnly Flags to Every Set-Cookie Response in Apache httpd | |
Header always edit Set-Cookie (.*) "$1; HTTPOnly" | |
Header always edit Set-Cookie (.*) "$1; Secure" | |
# END Add Secure and httpOnly Flags to Every Set-Cookie Response in Apache httpd | |
# BEGIN SSL Rewrite | |
<IfModule mod_rewrite.c> | |
RewriteEngine on | |
RewriteCond %{HTTPS} !=on [NC] | |
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L] |
OlderNewer