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 () { | |
var editorCount = 0; | |
$('.richtext').each(function () { | |
var sendFile = function (callback) { | |
data = new FormData(); | |
data.append("file", fileInput[0].files[0]); | |
$.ajax({ | |
url: "/upload/image", |
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 | |
namespace App; | |
use Illuminate\Database\QueryException; | |
class Increments | |
{ | |
public static function generate($key) | |
{ |
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
#!/bin/sh | |
# | |
# Adapted from: https://www.howtoforge.com/shell-script-to-back-up-all-mysql-databases-each-table-in-an-individual-file-and-upload-to-remote-ftp | |
# | |
# System + MySQL backup script | |
# Copyright (c) 2008 Marchost | |
# This script is licensed under GNU GPL version 2.0 or above | |
# --------------------------------------------------------------------- | |
######################### |
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
#!/bin/bash | |
# Syncronize a local Wordpress installation with a remote one. | |
# | |
# | |
# Requires wp-cli.phar installed somewhere. | |
WP_CLI=/usr/local/bin/wp | |
# Remote settings |
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 | |
class Aggregate implements \IteratorAggregate | |
{ | |
protected $var; | |
public function __construct($var = null) | |
{ | |
if (is_array($var)) { | |
$this->var = new ArrayIterator($var); |
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 namespace Zofe\Rapyd\DataForm\Field; | |
use Illuminate\Support\Facades\Form; | |
class Multiselect extends Field | |
{ | |
public $type = "checks"; | |
public $multiple = true; | |
public $size = null; | |
public $description = ""; |
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 | |
use Illuminate\Database\Console\Migrations\BaseCommand; | |
use Illuminate\Console\ConfirmableTrait; | |
use Illuminate\Database\Migrations\Migrator; | |
use Symfony\Component\Console\Input\InputOption; | |
class MigrateDone extends BaseCommand | |
{ |
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
var gulp = require('gulp'), | |
plumber = require('gulp-plumber'), | |
rename = require('gulp-rename'); | |
var autoprefixer = require('gulp-autoprefixer'); | |
var concat = require('gulp-concat'); | |
var jshint = require('gulp-jshint'); | |
var uglify = require('gulp-uglify'); | |
var imagemin = require('gulp-imagemin'), | |
cache = require('gulp-cache'); | |
var minifycss = require('gulp-minify-css'); |
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
# ---------------------------------------------------------------------- # | |
# Target DBMS: MySQL 5 # | |
# Project name: Northwind # | |
# Author: Valon Hoti # | |
# Created on: 2010-07-07 20:00 # | |
# ---------------------------------------------------------------------- # | |
DROP DATABASE IF EXISTS northwind; | |
CREATE DATABASE IF NOT EXISTS northwind; |
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
javascript: function loadScripts(array, callback) { | |
var loader = function(src, handler) { | |
var script = document.createElement("script"); | |
script.src = src; | |
script.onload = script.onreadystatechange = function() { | |
script.onreadystatechange = script.onload = null; | |
handler(); | |
}; | |
var head = document.getElementsByTagName("head")[0]; | |
(head || document.body).appendChild(script); |