Skip to content

Instantly share code, notes, and snippets.

@iamphilrae
iamphilrae / Monolog Log Levels Reference.md
Created June 16, 2026 11:04
Monolog Log Levels Reference

Monolog Log Levels Reference

Monolog follows the PSR-3 logging standard and provides eight log levels, ordered from least to most severe.

Level Purpose Typical Use
debug Detailed diagnostic information Variable dumps, execution flow, development troubleshooting
info General application events User logins, job starts/completions, API requests
notice Normal but noteworthy events Configuration changes, unusual but expected conditions
warning Unexpected events that don't stop execution Deprecated API usage, failed retries, missing optional data
let PayloadFormatter = {
CODEC: {
name: "mokosmart_lw001-bg-pro_chirpstack",
version: "1.5.0"
},
CONSTANTS: {
manufacturer: "MOKOsmart",
@iamphilrae
iamphilrae / HTML Maintenance Page
Created April 22, 2021 11:24
HTML Maintenance Page
<!doctype html>
<html lang="en">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex,nofollow">
@iamphilrae
iamphilrae / Laravel Clear Cache Commands
Created November 4, 2019 14:28
Laravel Clear Cache Commands
# Config Cache
php artisan config:clear
# Application Cache
php artisan cache:clear
# Route Cache
php artisan route:cache
# View Cache
@iamphilrae
iamphilrae / AWS S3 Public Bucket Policy
Created July 5, 2017 12:47
AWS S3 Public Bucket Policy
{
"Version":"2008-10-17",
"Statement":[{
"Sid":"AllowPublicRead",
"Effect":"Allow",
"Principal": {
"AWS": "*"
},
"Action":["s3:GetObject"],
"Resource":["arn:aws:s3:::bucket/*"
@iamphilrae
iamphilrae / MySQL Join Types
Last active November 4, 2019 14:22
MySQL Join Types
@see http://stevestedman.com/wp-content/uploads/MySqlJoinTypesThumbnail.png
@iamphilrae
iamphilrae / phpMyAdmin Export Filename Template, Including Date and Time
Last active August 14, 2025 13:51
phpMyAdmin Export Filename Template, Including Date and Time
@DATABASE@__%Y-%m-%d_%H-%M-%S
(function ($) {
/* Twitter Bootstrap Message Helper
** Usage: Just select an element with `alert` class and then pass this object for options.
** Example: $("#messagebox").message({text: "Hello world!", type: "error"});
** Author: Afshin Mehrabani <afshin.meh@gmail.com>
** Date: Monday, 08 October 2012
*/
$.fn.message = function(options) {
//remove all previous bootstrap alert box classes
this[0].className = this[0].className.replace(/alert-(success|error|warning|info)/g , '');