Skip to content

Instantly share code, notes, and snippets.

View microdesign's full-sized avatar
💭
Working hard

Martin Tonev microdesign

💭
Working hard
View GitHub Profile
@microdesign
microdesign / jQueryDroppable.js
Last active September 18, 2015 12:40 — forked from seanmcn/jQueryDroppable.js
jQuery Droppable (Accept only one Draggable)
$(".drop_area").droppable({
tolerance: "intersect",
accept: ".drop_item",
greedy: true,
drop : function(event, ui) {
$(this).droppable( "option", "disabled", true );
},
out : function(event, ui) {
$(this).droppable( "option", "disabled", false );
},
@microdesign
microdesign / gist:e1b8d74806fdb2f1a4c1
Last active November 12, 2015 08:46
Draw text to existing image and save it into new one - PHP
$ts = gmdate("D, d M Y H:i:s") . " GMT";
header("Expires: $ts");
header("Last-Modified: $ts");
header("Pragma: no-cache");
header("Cache-Control: no-cache, must-revalidate");
$imgPath = \URL::to( 'exiting_images/exiting.jpg' );
$save_image = 'user_images/test.jpg';
$save_to = public_path($save_image);