Skip to content

Instantly share code, notes, and snippets.

View qaharmdz's full-sized avatar

Mudzakkir qaharmdz

  • Java, Indonesia
View GitHub Profile
@qaharmdz
qaharmdz / minify.php
Created June 15, 2019 02:29
A small PHP-Script for minifying CSS
<?php
// specify your css-files and their order here
$cssFiles = array(
'normalize.css', 'style.css', 'print.css', 'colorbox.css'
);
// the file to write the compressed css to
$minFileName = 'minified.css';
// thats all, just call this file in your browser and it will
// build you a minimized css-file. then just link to this single
@qaharmdz
qaharmdz / ajax-form.js
Last active January 2, 2016 13:09 — forked from havvg/ajax-form.js
jQuery(function($) {
$('form[data-async]').on('submit', function(e) {
var $form = $(this);
var $target = $($form.attr('data-target'));
$.ajax({
type: $form.attr('method'),
url: $form.attr('action'),
data: $form.serialize(),