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
# Put these in ~/.bash_profile and save | |
# Then source the file to activate them | |
# source ~/.bash_profile | |
# | |
# Credit for original list | |
# https://github.com/tcnksm/docker-alias/blob/master/zshrc | |
# Get process included stop container | |
alias dps="docker ps -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
#leftcontent li.current_page_item a:link, #leftcontent li.current_page_item | |
a:visited, #leftcontent li.current_page_item a:hover, #leftcontent | |
li.current_page_item a:active { | |
font-weight: bold; | |
color:#FFFFFF; | |
padding:0px 0px 0px 7px; | |
background-position: 0px 0px; | |
background:url(images/li_bg.jpg) no-repeat; | |
} |
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="leftsidebar"> | |
<ul> | |
<li <?php if( is_home() ) { echo 'class="current_page_item"'; } ?>> | |
<a href="/wordpress/">Home</a></li> | |
<?php wp_list_pages( 'title_li=&depth=1' );?> | |
</ul> | |
</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
<html> | |
<head> | |
<script type='text/javascript' src='//maps.googleapis.com/maps/api/js?libraries=places&region=us&language=en&unit=mi&key=AIzaSyCg7Bzy277zhIIYinvQN0Q9sPr8s&callback'></script> | |
<script> | |
jQuery( function( $ ) { | |
function testMapAutoCompleteInit() { |
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
#!/bin/sh | |
# | |
# Used for automatic deployment from localhost to live server | |
# Triggered when `git push live` is run locally (tutorial below must be followed first) | |
# | |
# Based off this Digital Ocean tutorial | |
# https://www.digitalocean.com/community/tutorials/how-to-set-up-automatic-deployment-with-git-with-a-vps | |
# | |
# Put this script in your local repo folder. Then set perms | |
# {YOUR_REPO}/.git/hooks/post-receive |
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
<%= form_for(@item, html: {class: 'form_auth'}) do |f| %> | |
<% if @item.errors.any? %> | |
<div id="error_explanation"> | |
<h2><%= pluralize(@item.errors.count, "error") %> prohibited this item from being saved:</h2> | |
<ul> | |
<% @item.errors.full_messages.each do |msg| %> | |
<li><%= msg %></li> | |
<% end %> |
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
+// check honeypot field when a new comment is submitted | |
+// we hide the url field from normal visitors via css | |
+function at_pre_comment_check() { | |
+ | |
+ if ( ! empty( $_POST['url'] ) ) | |
+ wp_die( "Comment rejected because it triggered our spam filter. Disable any auto form filler and try again." ); | |
+ | |
+} | |
+add_action( 'pre_comment_on_post', 'at_pre_comment_check' ); |