Skip to content

Instantly share code, notes, and snippets.

View timramseyjr's full-sized avatar

Tim Ramsey timramseyjr

View GitHub Profile
@timramseyjr
timramseyjr / PublishesMigrations.php
Created August 8, 2022 16:01 — forked from DarkGhostHunter/PublishesMigrations.php
Publish migrations as assets instead of loading them.
<?php
namespace Vendor\Package;
use Generator;
use Illuminate\Support\Str;
trait PublishesMigrations
{
/**
@timramseyjr
timramseyjr / _readme.md
Created March 3, 2020 17:52 — forked from mrjones-plip/_readme.md
PHP Endpoint for Github Webhook URLs

PHP Endpoint for Github Webhook URLs

If you love deploying websites using Github, but for some reason want to use your own server, this script might be exactly what you need.

  1. Put github.php somewhere on your PHP-enabled web server, and make it accessible for the outside world. Let's say for now the script lives on http://example.com/github.php
@timramseyjr
timramseyjr / Envoy.blade.php
Created November 4, 2019 21:34 — forked from gvsrepins/Envoy.blade.php
A Laravel envoy script for deployment
@servers(['production' => 'productionserver', 'local'=> '[email protected] -p 2222'])
{{-- Configuration section --}}
@setup
/*
|--------------------------------------------------------------------------
| Git Config
|--------------------------------------------------------------------------
|
@timramseyjr
timramseyjr / digital-ocean-promo-codes.md
Last active March 21, 2018 19:45
Digital Ocean Promo Codes 2017

Digital Ocean Promo Codes 2018

Save $20 when you open a digital ocean account with Promos following these steps.

  1. Use this link https://goo.gl/69hJEr to activate $10 in account credit
  2. Enter one of the following promo codes for $10 savings in the coupon box at checkout
  • CodeAnywhere10
  • LOWENDBOX
  • CODEANYWHERE
@timramseyjr
timramseyjr / favicon.html
Created July 6, 2017 11:42 — forked from bcherny/favicon.html
100% cross browser favicon declaration
<!--
favicons (see http://www.jonathantneal.com/blog/understand-the-favicon)
---
icon format dimensions documentation
---- ------ ---------- -------------
apple-touch-icon PNG 152x152 https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/MobileHIG/IconMatrix.html#//apple_ref/doc/uid/TP40006556-CH27-SW1
icon PNG 96x96
shortcut icon ICO 32x32
msapplication-TileImage PNG 144x144
@timramseyjr
timramseyjr / jquery.smoothScrollTo.js
Created July 5, 2017 19:26
jQuery Smooth scrollTo
$('.rightorder a[href*="#"]').on('click',function(e) {
e.preventDefault();
var target = $(this).attr('href');
var div = $(target);
if (div.length) {
$('html,body').animate({
scrollTop: div.offset().top - 90
}, 1000);
}
});
@timramseyjr
timramseyjr / fadeInScroll.js
Last active March 24, 2017 14:33
Fade In Content when scrolling
$.fn.fadeInScroll = function(options) {
$(window).unbind('.checkFades');
var elements = $(this);
var settings = $.extend({
minDistance: 80 * $(window).height() / 100,
speed:500
}, options );
$(elements).each(function(){
$(this).css({opacity:0});
});
@timramseyjr
timramseyjr / bootstrap-tabcollapse-wactive.js
Last active February 20, 2017 17:34
Bootstrap Tab Collapse with modifications for Active Header Class
!function ($) {
"use strict";
// TABCOLLAPSE CLASS DEFINITION
// ======================
var TabCollapse = function (el, options) {
this.options = options;
this.$tabs = $(el);
@timramseyjr
timramseyjr / ccembed.html
Last active February 20, 2017 16:39
Alternative to the CC Embed which doesn't error handle correctly for me
<script>
$(document).ready(function() {
$("#ctct_signup").submit(function(e) {
var formData = $("#ctct_signup").serialize();
$.ajax({
type : 'POST',
url : 'https://visitor2.constantcontact.com/api/signup',
data : formData,
dataType : 'json',
success: function(data){
$.fn.moreless = function(options){
var settings = {
'showChar': 100,
'ellipsestext': "...",
'moretext': "Show more >",
'lesstext':"Show less"
};
if (options) {
$.extend(settings, options);
}