Code Samples

CSV File Manipulator

A recent technical assessment.
GitHub repository
Write a PHP web application that can do the following:
  1. Allow the user to upload a csv file. Assume the csv file has column headers in the first row.
  2. Display the uploaded csv as a table in the browser (you may want to use Bootstrap DataTables).
  3. Allow the user to define new columns in the table based on applying operations to existing columns.

    To add a new column, the user provides a column name and a formula which can consist of operations on existing columns (example below).

    To simplify the scope of this exercise, assume all the data in the csv are either numeric or string (i.e., don't worry about parsing text formatting), and the only operations you need to handle are arithmetic (+ - * /) and concatenate (&). Assume column headers in the csv have no spaces; and require that user-defined column names have no spaces.

  4. Display updated table in the browser, calculating the contents of the new column according to the formula provided. If the operation is invalid for a row(e.g., applying arithmetic operator to non-numeric value) display NA.
  5. Make sure the application fails elegantly, e.g. helpful error messages if the formula is invalid.
Some of the tech
  • Vanilla PHP 7
    The specs for this app suggested I use vanilla PHP instead of a framework, so that's what I did. The only class that I did not develop from a blank page was the autoloader class. That was a class I had laying around from another project, but I developed it from a blank page, just not during this project. The structure of the project is very Laravel-ish. I have routes defined in index.php that could be direct drop-ins for a Laravel project. The routes are mapped to a Pages controller that does a little logic and then spits out a view. The views are php/html files that are like templates.
  • Javascript.
    The only Javascript I "wrote" for this app was copied and pasted from the mdbootstrap site to initialize the data table. There is some Javascript included for the app, but that is all for bootstrap.
  • Html / CSS.
    I am not a designer, so bootstrap does all the heavy lifting in terms of making the presentation acceptable. I am using the material design version of bootstrap, but the classes I chose to use are mostly the regular bootstrap classes.
  • Git / Github.
    The project uses git and github. There is a link in the upper right hand corner to view the source. I directly downloaded mdbootstrap rather than use npm. I have excluded the bootstrap files from the repository, so if you clone it, you will need to download mdbootstrap as an additional step.

DogSledRides.com

An ancient website
GitHub repository

The site is basically a database about dog sledding and dog powered sports. This was my first website, and it has been around since 1996. I am currently going through the site and converting it to Laravel. I am just using blade templates for rendering, but will likely convert it to React after I finish the backend port.

Some of the tech
  • Laravel 5.5 (because the server is running 7.1.24)
  • Javascript - not much going on with javascript yet. A little form validation is all.
  • Bootstrap is doing the heavy lifting for the css.
  • There are two auth tables; one for kennel users, and one for super admins. Will likely add a third for those looking for mushing jobs.

Recent Technical Assessment

A test of my Typescript, Express and Node skills.
GitHub repository

This server does not have node, so there is no live demo. The project is a REST API that handles requests to create customers and events, and then handles a couple get events requests, like all events, events in the last 24 hours, and events by customer.

Some of the tech
  • Typescript 3.5.3
  • Node
  • Express 4.17
  • Joi 15.0.3

Another Recent Technical Assessment

A test of my PHP, MySql and React skills.
GitHub repository

This was a bunch of code to write, so why not make it public.

Some of the tech
  • React 15.6.2 SPA with BrowserRouter.
  • PHP REST API called via Axios with CORS handling and pagination.
  • MySql queries with subqueries linking up to five tables.
  • Bootstrap components including Cards and Modal
  • FontAwesome
  • Webpack

dsrwp.com

Full website for Dog Sled Rides of Winter Park

This site has evolved over the years and has way too many features to list all of them. Most of the cool stuff is in the admin dashboard, so not visible to the public.

Some of the tech
  • Uses the Bandwidth API for text messaging, calling, and voicemail managemnt. There is an integrated view of customer communications that looks like text messaging app.
  • Customizable communication templates that are filled in with customer reservation details.
  • NOAA SOAP protocol for weather forecast data that is then inserted into customer emails.
  • Google sign-in to secure the backend.
  • Google Gmail and Calendar API.
  • The public facing reservation system was developed in 2007. The code is a bit clumsy, and could stand an overhaul.
  • etc...

Electric Bikes in Grand County

A website about electric bicycle laws, trails and rentals in Grand County Colorado.

I like riding my electric bike, and there is a bit of confusion about the applicable laws. The site details the laws and suggests roads, trails and routes to take with your e-bike. There is also a range calculator for your battery that will help riders select a power level to make sure they make it home. The site is still evolving...

Some of the tech
  • React SPA with BrowserRouter
  • PHP REST API with CORS handling.
  • Bootstrap styling and components.
  • Webpack

Notes App

A simple notes app using local storage.
GitHub repository

Just exploring more react with a notes app that stores the notes in local storage.

Some of the tech
  • React
  • localStorage with JSON stringify and parse
  • Bootstrap
  • FontAwesome
  • Webpack