This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
db: | |
# We use a mariadb image which supports both amd64 & arm64 architecture | |
image: mariadb | |
# If you really want to use MySQL, uncomment the following line | |
#image: mysql:8.0.27 | |
command: '--default-authentication-plugin=mysql_native_password' | |
volumes: | |
- db_data:/var/lib/mysql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// NOTE - This code does not seem to show motion events from the beacon. | |
/** | |
...dependencies & engine | |
"dependencies": { | |
"@abandonware/bluetooth-hci-socket": "^0.5.3-8", | |
"@abandonware/noble": "^1.9.2-15", | |
"node-beacon-scanner": "^0.2.2" | |
}, | |
"engines": { | |
"node": "12.22.12", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Here is some extra practice work for javascript arrays and objects. | |
const data = [ | |
{ | |
id: 2, | |
name: 'Michael', | |
address: { | |
state: 'CA', | |
zip: 94501 | |
} | |
}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: TheAudioBeatnik Category Slideshow | |
* Description: A category page slideshow using Slick.js and WP Plugin Advanced Custom Fields | |
* Author: Adam LaBarge | |
* Version: 1.0 | |
* Author URI: https://www.linkedin.com/in/adamlabarge | |
*/ | |
class tab_CategorySlideShow { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Sample Plugin | |
Plugin URI: | |
Description: Sample code for the Portland WordPress MeetUp Hooks and Filters Talk | |
Version: 1.0.0 | |
Author: adamplabarge | |
Author URI: https://github.com/adamplabarge | |
Text Domain: sample-plugin | |
License: GPLv2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Some python from a free python class offered by The Tech Academy Portland | |
https://www.meetup.com/techacademy/ | |
""" | |
import math | |
from random import randint | |
randMin = 0 | |
randMax = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Show hidden characters
{ | |
"presets": ["es2015"] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action('genesis_before', function() { | |
global $wpdb; | |
$post_type = 'product'; | |
$query = " | |
SELECT DISTINCT($wpdb->postmeta.meta_key) | |
FROM $wpdb->posts | |
LEFT JOIN $wpdb->postmeta |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$highlights = new WP_Query($args); | |
$sort = function(&$posts) { | |
$props = array('year', 'authors'); | |
usort($posts, function($a, $b) use ($props) { | |
if ($a->$props[0] == $b->$props[0]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function htmlEncode(str) { | |
return str.replace(/&/g, '&') | |
.replace(/"/g, '"') | |
.replace(/'/g, ''') | |
.replace(/</g, '<') | |
.replace(/>/g, '>'); | |
} |
NewerOlder