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 | |
function login_with_email_address($username) { | |
$user = get_user_by_email($username); | |
if(!empty($user->user_login)) | |
$username = $user->user_login; | |
return $username; | |
} | |
add_action('wp_authenticate','login_with_email_address'); |
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 | |
add_action('headway_setup_child_theme', 'disable_design_editor'); | |
function disable_design_editor() { | |
remove_theme_support('headway-design-editor'); | |
} |
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
@test = "https://api.twitter.com/1/users/show.json?screen_name=TwitterAPI&include_entities=true" | |
@ip = "173.236.160.229" | |
c = Curl::Easy.new(url) do |curl| | |
curl.url = @test | |
curl.interface = @ip | |
end | |
data = c.perform | |
@result = JSON.parse(data.body_str) |
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
/* | |
Theme Name: Headway Fire Child Theme | |
Theme URI: http://headwaythemes.com | |
Description: A fiery take on a powerful element. This child theme features gradients and rounded corners in all the right places. It also contains separate widget styles, text shadows and a subtle black background. | |
Version: 0.1 | |
Author: Headway Themes | |
Author URI: http://headwaythemes.com | |
Template: headway | |
*/ |
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 | |
add_action('headway_setup_child_theme', 'hfct_remove_theme_support'); | |
function hfct_remove_theme_support() { | |
// Removes the Design Editor from the Visual Editor | |
remove_theme_support('headway-design-editor'); | |
// Removes Headway's basic CSS file | |
remove_theme_support('headway-structure-css'); | |
// Removes Headway's Grid |
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
html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font:inherit;vertical-align:baseline;}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block;}body{line-height:1;margin:0;}ol,ul{list-style:none;}blockquote,q{quotes:none;}blockquote:before,blockquote:after,q:before,q:after{content:'';content:none;}table{border-collapse:collapse;border-spacing:0;}a{outline:none;}img{outline:none;}.clearfix:before,.clearfix:after{content:"";display:table;}.clearfix:after{clear:both;}.clearfix{zoom:1}div.wrapper{margin:0 auto}div.grid-container{height:auto;margin:0}div#whitewrap{width:100%;float:left}.clear{cle |
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 | |
// This contains everything below the post. Has Social Sharing, Affiliate box, and Author Bio | |
add_action('headway_after_entry_content', 'aj_bio_share'); | |
function aj_bio_share() { | |
if(is_single()) { ?> | |
<div class="post-ending"></div> | |
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 | |
add_filter('language_attributes', 'add_opengraph_doctype'); | |
function add_opengraph_doctype( $output ) { | |
return $output . ' xmlns:og="http://opengraphprotocol.org/schema/" xmlns:fb="http://www.facebook.com/2008/fbml"'; | |
} |
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
function mytheme_admin_bar_render() { | |
global $wp_admin_bar; | |
$wp_admin_bar->remove_menu('headway'); | |
} | |
add_action( 'wp_before_admin_bar_render', 'mytheme_admin_bar_render' ); |
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 | |
add_action('headway_block_close_4', 'add_twitter_to_navigation'); | |
function add_twitter_to_navigation() { | |
echo '<li>twitter button code goes here</li>'; | |
} |