Skip to content

Instantly share code, notes, and snippets.

View Hernandesjunio's full-sized avatar

Hernandes Junio de Assis Hernandesjunio

  • GFT
  • Belo Horizonte, MG - Brasil
View GitHub Profile
@cmatskas
cmatskas / fileupload.js
Created October 5, 2015 22:42
File Upload jQuery
$('#txtUploadFile').on('change', function (e) {
var files = e.target.files;
//var myID = 3; //uncomment this to make sure the ajax URL works
if (files.length > 0) {
if (window.FormData !== undefined) {
var data = new FormData();
for (var x = 0; x < files.length; x++){
data.append("file" + x, files[x]);
}
@leocomelli
leocomelli / git.md
Last active October 19, 2025 19:00
Lista de comandos úteis do GIT

GIT

Estados

  • Modificado (modified);
  • Preparado (staged/index)
  • Consolidado (comitted);

Ajuda

/**
Code copyright Dustin Diaz and Ross Harmes, Pro JavaScript Design Patterns.
**/
// Constructor.
var Interface = function (name, methods) {
if (arguments.length != 2) {
throw new Error("Interface constructor called with " + arguments.length + "arguments, but expected exactly 2.");
}
this.name = name;