Skip to content

Instantly share code, notes, and snippets.

@GLC
GLC / Fancy File Inputs.js
Created June 20, 2012 05:05
Fancy File Inputs (file name INSIDE button on change)
var SITE = SITE || {};
SITE.fileInputs = function() {
var $this = $(this),
$val = $this.val(),
valArray = $val.split('\\'),
newVal = valArray[valArray.length-1],
$button = $this.siblings('.button');
if(newVal !== '') {