JSFiddle

  • Display a list

    Quick demo of displaying a list in Angular

    var bensApp = angular.module('benApp', ['ngRoute']);
    bensApp.controller('benCtrl', function($scope) {
      $scope.cats = [{
        'name': 'Kismet',
        'breed': 'Domestic Shorthair'
      }, {
        'name': 'Bandit ...
  • Unifirst Sample #16 is the latest revision

    Working with @paxton to convert jQuery app to Angular

    var app = angular.module("unifirstApp", []);
    
    //provide an array with the scope and http DI items with an anonymous inner function ...
  • Timeout Example

    AngularJS Timeout Example

    var nisSnapshotControllers = angular.module('nisSnapshotControllers', []);
    nisSnapshotControllers.controller('Page1Controller', ['$scope', 'dataRefresh',
      function($scope, dataRefresh) {
        $scope.counter = 0;
        $scope.interval = 500;
        var ...
  • Fieldset Legends #1 is the latest revision

    In working a 508 compliance issue, I need to experiment a little with fieldset legends. Specifically, I need to have a legend for all fieldsets, in order to be 508 compliant, but I don't want to the legend to show, because it doesn't look right in the application.

    <div id="fs-exp">
        <fieldset id="fset">
            <legend id="fset-legend">The Legend</legend>
            <label for="fset-checkbox1">Input 1</label>
            <input type="checkbox" id="fset-checkbox1"></input>
            <label for="fset-checkbox2">Input 2</label>
            <input type="checkbox" id="fset-checkbox2"></input>
        </fieldset>
    </div>
  • Pure JS playground #4 is the latest revision

    No-Library (pure JS), HTML, CSS, JavaScript

    // step 1
    var myButton = document.getElementById('the-button');
    
    // step 2 - add the right event and function name
    myButton.addEventListener('click', myButtonFunction ...
  • ROM - Pre & Post JR

    ACR 305 Corrected an issue where the range overlap was causing incorrect radio selections for Plantar Flex vs Dorsiflexion. Corrected it by finding highest limitation of EACH row, then comparing those two.

    $(document).ready( function() {
        initAnkleROMFields();
    });
    
    function initAnkleROMFields() {
    
        var inputs = $("div[id='group-RangeofMotion(DC5271)-wrapper'] input[type=text]");
        var postOpInputs = $("div[id ...
  • ROM - Fixing Defects

    ACR 305

    $(document).ready( function() {
        initAnkleROMFields();
    });
    
    function initAnkleROMFields() {
    
        var inputs = $("div[id='group-RangeofMotion(DC5271)-wrapper'] input[type=text]");
        var minVal;    //minimum value ...
  • Range of Motion Experiment #33 is the latest revision

    ACR 305

    /**
     * experimental javascript to support ACR 305:
     * auto selection of radio buttons when the user selects a range
     * from the range ...
  • YUI accordion

    YUI 3.4.1, HTML, CSS, JavaScript

    YUI({
        gallery : 'gallery-2012.08.15-20-00'
    }).use( 'gallery-accordion',
            'node-menunav',
            function(Y) {
    
        
    
        var accordion = new Y.Accordion({
            srcNode: "#acc1",
            useAnimation: true,
            collapseOthersOnExpand ...
  • Nav menu prototype

    Attempting yet another navigation menu prototype

    YUI().use(
        'node',
        'transition',
        'event-mouseenter',
        'node-menunav',
        function(Y) {
    
        /* global variables */
        var bbox = Y.one('#menu-bounding-box');
        var mainMenu = Y.one('#menu-content-box ...