Skip to content

Instantly share code, notes, and snippets.


Kevin Blues kbluescode

View GitHub Profile

Keybase proof

I hereby claim:

  • I am kbluescode on github.
  • I am kbluescode ( on keybase.
  • I have a public key ASAHxqlgpVoLO6pw3FM4ogxS3qNCNidu6o997ifW5k-LAgo

To claim this, I am signing this object:

kbluescode / PT Web Oct 2016 - Bootstrap Page
Last active Nov 30, 2016
The bootstrap page we were making in the last tutorial
View PT Web Oct 2016 - Bootstrap Page
<!doctype html>
<link rel="stylesheet" href="" />
<link rel="stylesheet" href="app.css" />
<title>Bootstrap demo!</title>
<div class="fluid-container">
<div class="jumbotron">
kbluescode / app.js
Created Nov 22, 2016
PT Web - Oct 24 - Week 5 Day 1 Tutorial JavaScript
View app.js
$(document).ready(function() { // run this when the page is done loading
var form = $("form") // capture the form
form.on("submit", function(event) { // when we submit the form...
var usernameLabel = $("#username-label") //get the username label and inputs themselves
usernameLabel.text("Username") // set the username label to its default value
var usernameInput = $("#username")
var passwordLabel = $("#password-label") //get the password label and inputs themselves
kbluescode / validation.js
Created Apr 23, 2016
PT-Web-Fundamentals-March - JavaScript Validations
View validation.js
// this is some jquery to say when the document is ready, run whatever is
// inside this function
$(function() {
// function to check whether the form is valid or not
function isValid() {
// removes the has-error class from anything that has it
// basically, this removes all the error states from our form
kbluescode / yellow_pager.rb
Created Apr 12, 2016
PT-Web March Yellow Pager
View yellow_pager.rb
# Write a method that accepts a 10-character string of letters and
# outputs a corresponding phone number string.
# If the input letter string isn't 10 characters, you should return false. Not valid.
# 2 -> A B C
# 3 -> D E F
# 4 -> G H I
# 5 -> J K L
# 6 -> M N O
# 7 -> P Q R S
kbluescode / fizzbuzz.rb
Created Apr 8, 2016
PT Web March - FizzBuzz
View fizzbuzz.rb
# First I like to write out the problem and try to start breaking it into pieces
# ==============================================================================
# grab a list of numbers
# for each one, check if divisible by 3, 5, or both
# if divisible by 3, print 'Fizz'
# if divisible by 5, print 'Buzz'
# if both, print 'FizzBuzz'
# to test running this, uncomment the blocks of code you want to run ----------
kbluescode / index.html
Created Apr 2, 2016
PT-Web March Day 2
View index.html
<!doctype html>
<title>Hello, World!</title>
<h1>This is the most important header on the page</h1>
<h2>This is the 2nd most important head on the page</h2>
<p>Any text here is a <strong>paragraph.</strong>
kbluescode / index.html
Created Mar 30, 2016
PT Web March - Day One
View index.html
<!doctype html>
<link rel="stylesheet" href="main.css" />
<title>Hello, World!</title>
<img src="" />
<table id="name-color-table">
View validation.js
$(function() { //run when the page loads
$('#submit').on('click', function() { //when you click submit
$('.has-error').removeClass('has-error') //remove last batch of errors
var valid = true //starts off totally valid
var username = $('#username') //grab the username input
var usernameLabel = $("#username-label") //grab the username label
var usernameText = username.val() //grab the username input's text
View animal.rb
class Animal
# the double @ sign indicates this variable belongs to the class
@@count = 0
def initialize(name)
# the single @ sign indicates this variable belongs to the individual object
@name = name
@@count += 1