Web Development

How to Create an On-Demand Feature for Your Alexa Skill

Submitted by Danny on Fri, 07/02/2021 - 13:18

As 2020 was coming to a close and 2021 was just around the corner, I was finishing development of a new version of our skill for the Alexa smart speaker. It was a total re-write, and it changed the skill from being able to perform only a single intent (play our live stream) to providing a dialog-based menu of many intents to choose from. With the new skill, listeners can choose to either play our live stream, play our HD2 live stream, play the latest newscast recording, or play an on-demand. (One day I would like to add another intent: make a donation.)

How to use versioning with AWS Lambda and Alexa Skills Kit (ASK), a step by step guide

Submitted by dannix on Fri, 04/05/2019 - 14:15

I learned a valuable lesson on the morning after submitting my latest Alexa skill for certification. I had an email from the Alexa certification team letting me know that their tests had failed. I thought that was odd because everything was working perfectly fine when I left work the previous day. I was using AWS Lambda to host the back-end code (within a Node.js environment) and hadn't set up the versioning system because I didn't know about it. [update: I'm now using the AWS CLI to locally host my code and push it to Lambda, which is what I recommend.

Make your own conditional fields in Drupal 7 by "hacking" the hook_form_alter() function with JavaScript injection

Submitted by Danny on Fri, 04/14/2017 - 16:44

When I needed a conditional field for a Drupal 7 content type, of course I just googled "drupal conditional fields" to see if a module exists. One did exist, but its D7 release came with a big, red flag warning any would-be downloaders that it's not supported any longer and is vulnerable to security issues. Instead of risking it on the entrerprise-level website, I decided to code up a solution myself. And I would use JavaScript inserted by the PHP code. Easy!

Exporting/migrating a Joomla website to Drupal7, with code

Submitted by Danny on Thu, 05/19/2016 - 14:16

After building the new webiste for Kansas Public Radio using Drupal 7, I needed a way to export all of the old articles from our Joomla website to the new website. I could have experimented with the Feeds module for Drupal or another Joomla to Drupal solution, but our installation of Joomla was sooooo old and outdated that I couldn't trust anything. I decided to write my own bit of code.

The Reviews are In: Functional Programming in JavaScript "is AWESOME"

Submitted by Danny on Thu, 08/06/2015 - 12:57

From the very beginning, the goal with Functional Programming in JavaScript was to strip the veneer off the language to expose its inner beauty and functional roots, a necessary step in helping the reader to fully understand both the language and the functional programming paradigm. And now that some reviews are coming in, it appears that the goal has been met.

Creating Podcast XML from Drupal content

Submitted by Danny on Thu, 07/09/2015 - 13:11

I needed to create some podcasts for Kansas Public Radio, which uses the Drupal Content Management System (CMS). I couldn't find a satisfactory Drupal module that could create the RSS data that iTunes needs, so I had to come up with my own solution. IIRC, Drupal Feeds would have worked great but iTunes needs specific XML tags (i.e. <itunes:description>, <itunes:category>, etc) that Drupal Feeds couldn't provide. I also dried Drupal Views PHP but it was too buggy and I also couldn't get the code to output outside of the template.