programming

[RELEASE] Bootstrap CRUD Generator

  • Posted on: 30 March 2016
  • By: davis

Go to the CRUD Generator

I'm pleased to announce that I've developed a Bootstrap CRUD application generator. Tired of manually building forms for basic SQL events? Use my tool to generate CRUD pages for your tables.

A painless way to create PHP/MySQL/Bootstrap CRUD apps

Generate a basic Bootstrap-themed CRUD (Create, Read, Update, Delete) application based on your MySQL SELECT, UPDATE, or CREATE query.

Bash - Get Name of Parent Directory

  • Posted on: 2 March 2016
  • By: davis

For the path /foo/bar/, if the current directory is bar, and we want to get the name of the parent directory (i.e. foo)

path="$( cd "$( dirname $0 )" && cd -P "$( dirname "$SOURCE" )" && pwd )"
parentName=$(basename -- "$(dirname -- "$path")")
echo $parentName # will return parent directory's name

This resolves symbolic links (sidestepping the error where it returns "." for the parent dir). Give it a try.

Alternative to Cron for NearlyFreeSpeech Users

  • Posted on: 16 February 2016
  • By: davis

I use the server host NearlyFreeSpeech for all of my personal website-related things nowadays. They are extremely cheap, and their community-driven support is great.

Unfortunately, they don't have crontab enabled. Here's a workaround for enabling cron-like functionality on a NearlyFreeSpeech hosting instance.

In my case, I needed to curl multiple public-facing URL's in order to refresh some vital information. I wanted to do that on a schedule.

Building An Arduino-Powered Infinity Table

  • Posted on: 7 July 2015
  • By: davis

Matt Ibarra and I wanted a fun project. My girlfriend Amanda wanted a table.

Thus, we decided on an Infinity table. We accomplished this project in one night!

We wanted a coffee table to play around with, and the infinity effect seemed pretty cool. We've tried building an LED hoop before, with moderate success. This time, we wouldn't have to deal with the downsides of stuffing LEDs in a hoop.

Retrieving RSS with Javascript and NoCache

  • Posted on: 30 March 2015
  • By: davis

I use Google Feeds API to power my RSS fetching for a couple applications. One inevitable problem with dynamically accessing RSS feeds is that they tend to be cached.

The easiest cache-busting Javascript trick, in my opinion, is to append your RSS Feed URI with ?nocache and a random value.

UPDATE 4/42015 - Removed the trailing '/' from the RSS URL below. The code will fail with Google Feed's API if you do not remove the trailing '/'. Alternatively, you may replace the ? with & if you wish to leave the slash.

Pages