Skip to content

Instantly share code, notes, and snippets.

🐳
sploosh

Joel Lisenby JoelLisenby

🐳
sploosh
Block or report user

Report or block JoelLisenby

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@JoelLisenby
JoelLisenby / find_invisible_horizontal_scroll_elements.js
Last active Dec 13, 2019
JavaScript to find hidden horizontal scroll elements. Paste into browser JS console and hit enter.
View find_invisible_horizontal_scroll_elements.js
var docWidth = document.documentElement.offsetWidth;
[].forEach.call(
document.querySelectorAll('*'),
function(el) {
if (el.offsetWidth > docWidth) {
console.log(el);
}
}
);
@JoelLisenby
JoelLisenby / off.reg
Created Jun 5, 2019 — forked from CHEF-KOCH/off.reg
Windows 10 ads, turn it off!
View off.reg
Windows Registry Editor Version 5.00
; Turn off File Explorer ads
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced]
"ShowSyncProviderNotifications"=dword:00000000
; Turn off Start Menu suggestions
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager]
"SystemPaneSuggestionsEnabled"=dword:00000000
View hero_video.html
<div id="hero_video_container">
<video autoplay muted loop id="hero_video">
<source src="/videos/video.mp4" type="video/mp4" />
<source src="/videos/video.webm" type="video/webm" />
</video>
</div>
<style>
#hero_video_container {
position: relative;
width: 100%;
@JoelLisenby
JoelLisenby / ffmpeg.sh
Last active Sep 6, 2019
ffmpeg video encoding for web (chrome, firefox, safari, etc)
View ffmpeg.sh
# h265
ffmpeg -i input.mp4 -c:v libx265 -vf scale=1280:720 -pix_fmt yuv420p output.mp4
# h265 with colorspace specified
ffmpeg -i input.mp4 -c:v libx265 -vf scale=1280:720 -pix_fmt yuv420p -color_primaries bt709 -color_trc bt709 -colorspace bt709 output.mp4
# h265 with colorspace specified and no audio
ffmpeg -i input.mp4 -c:v libx265 -vf scale=1280:720 -pix_fmt yuv420p -color_primaries bt709 -color_trc bt709 -colorspace bt709 -an output.mp4
# webm
@JoelLisenby
JoelLisenby / export_opencart_orders.sql
Last active Mar 5, 2019
Queries to export customers and orders from OpenCart as CSV for Import into WooCommerce via WPImportAll plugin
View export_opencart_orders.sql
/*
SQL Queries to export customers and orders from OpenCart database as CSV to import into
WooCommerce via the WP All Import plugin with the WooCommerce Add-On
http://www.wpallimport.com/
- Use wp_all_import_templates.txt with the plugin to save column matching time.
- Currently does not import order status
*/
@JoelLisenby
JoelLisenby / new_site.sh
Created Jan 10, 2019
Bash script to set up a new project folder for wpengine when using vscode with the sftp extension
View new_site.sh
#!/bin/bash
echo -e "Domain: \c "
read domain
echo -e "Slug: \c "
read slug
echo -e "Password: \c "
read password
dir="$domain/ftp/public/.vscode"
View autonomous_ai_desk_reset.md

Hard Reset

  1. Unplug the desk for 20 seconds. Plug it back in. Wait a full 20 seconds.
  2. Press the up and down buttons until the desk lowers all the way and beeps or 20 seconds pass.
  3. Release both buttons.
  4. Press the down buttons until the desk beeps one more time or 20 seconds pass.
View lighthouse-accessibility-audit-ids.txt
"accesskeys",
"aria-allowed-attr",
"aria-required-attr",
"aria-required-children",
"aria-required-parent",
"aria-roles",
"aria-valid-attr-value",
"aria-valid-attr",
"audio-caption",
"button-name",
@JoelLisenby
JoelLisenby / wp_migration.md
Last active Apr 10, 2018
WordPress Site Migration
View wp_migration.md

WordPress Site Migration

Step 1: Backup Dev Site

  • dump database mysqldump -u user_name -p db_name > database_dev.sql
  • files_dev.zip/tar.gz all website files and folders zip -r files_dev.zip /var/www/
  • Store in directory outside of public directory cp files_dev.zip ~/site-backup/ && cp database_dev.sql ~/site-backup/

Step 2: Backup Live Server

  • dump database mysqldump -u user_name -p db_name > database_live.sql
  • files_live.zip/tar.gz all website files and folders zip -r files_live.zip /var/www/
@JoelLisenby
JoelLisenby / gdpr.md
Last active May 4, 2018
GDPR Summary
View gdpr.md

General Data Protection Regulation [GDPR] Summary

Must have and store the lawful basis of processing for each contact.

  • Consent (opt-in)
    • Must be told (notified) of what they are opting into.
    • Needs to affirmatively opt-in with an unchecked box. (only opts in for what they were notified they are opting into, not everything you want to send.)
    • Consent must be granular, covering the various ways you use the users data (e.g. email, calls).
    • Must log auditable evidence of what the user consented to: the notice and when they consented.
  • Performance of a contract (customer you need to send bills to)
  • Legitimate interest (customer you want to send products related to what they have)
You can’t perform that action at this time.