Skip to content

Instantly share code, notes, and snippets.

View johnnyopao's full-sized avatar
✌️

Johnny Opao johnnyopao

✌️
View GitHub Profile
@johnnyopao
johnnyopao / customMobileCssUnbounce.html
Created June 13, 2015 16:36
Unbounce mobile breakpoint
<style>
@media (max-width: 600px){
/*Custom CSS HERE */
}
</style>
Verifying my Blockstack ID is secured with the address 1LicUSLFtg4GwSsLBCsB6TLkUbvhV4TNwR https://explorer.blockstack.org/address/1LicUSLFtg4GwSsLBCsB6TLkUbvhV4TNwR
FROM amazonlinux:latest
WORKDIR /app
# install pip
RUN curl -s https://bootstrap.pypa.io/get-pip.py | python
# requirements for compiling JAGs
RUN yum install -y \
gcc \
import os
import sys
CWD = os.path.dirname(os.path.realpath(__file__))
sys.path.insert(0, os.path.join(CWD, "lib"))
# The example below was taken and modified from the pyjags documentation
# https://pyjags.readthedocs.io/en/latest/getting_started.html
import pyjags
@johnnyopao
johnnyopao / convert.sh
Created December 24, 2018 05:46
ffmpeg - Convert videos to smaller scale. Clean up filenames. Backup original
for vid in */*.mp4
do
new_file_name=$(echo $vid | awk '{ gsub(/ /, "-"); gsub(/[&|\+|{|}]/, ""); gsub(/-+/, "-"); gsub(/-_-/, "-"); gsub(/(-[0-9]{3,})/, "") }; 1')
ffmpeg -i "./$vid" -filter:v "scale=w=800:h=-1" "./${new_file_name}"
backup_dir="./backup/$(dirname "$vid")"
mkdir -p $backup_dir && cp "./$vid" $backup_dir
@johnnyopao
johnnyopao / text-image-GA-events.js
Last active December 15, 2022 11:39
Triggering GA events for image/text links on Unbounce
<script>
// Replace #lp-pom-image-13 with the ID of your image or text box. Be sure to retain the trailing 'a'
$( '#lp-pom-image-13 a' ).click( function(event) {
event.preventDefault();
var buttonLink = $(this).attr("href");
if (typeof ga != 'function') {
window.location = buttonLink;
@johnnyopao
johnnyopao / left-align-root.css
Created October 14, 2014 23:50
Align Page content Left on Unbounce Pages
<style>
#lp-pom-root {
float:left;
}
</style>
@johnnyopao
johnnyopao / ubAdwordsCallTracking.html
Last active December 15, 2022 11:40
Unbounce - Adwords Call tracking - Consolidated (text/links/buttons) - See full instructions here: http://documentation.unbounce.com/hc/en-us/articles/203509834
<script>
// NOTE: If you want to track these links as conversion goals on Unbounce,
// change 'clkn' to 'clkg' in the commented areas below
// Add the button ID's to this array that you want tracked
// For example: ['#lp-pom-button-12', '#lp-pom-button-20']
var callButtons = [];
var ubCallback = function(formatted_number, unformatted_number) {
var numberLinks = document.getElementsByClassName('number_link');
@johnnyopao
johnnyopao / closeFormConfirmationDialog.md
Last active December 15, 2022 11:41
Close your Unbounce Form Confirmation Dialog lightbox with a button

Set the buttons URL to

javascript:lp.jQuery.ubpoverlay.close()