Skip to content

Instantly share code, notes, and snippets.

View drajathasan's full-sized avatar

Drajat Hasan drajathasan

View GitHub Profile
@drajathasan
drajathasan / rrmdir.php
Created June 19, 2021 08:46 — forked from jmwebservices/rrmdir.php
PHP recursive rmdir
<?php
/**
* Recursively empty and delete a directory
*
* @param string $path
* @ref https://gist.github.com/jmwebservices/986d9b975eb4deafcb5e2415665f8877
*/
function rrmdir( string $path ) : void
{
@drajathasan
drajathasan / chat-frontend.js
Created March 11, 2020 13:46 — forked from martinsik/chat-frontend.js
Node.js chat frontend and server
$(function () {
"use strict";
// for better performance - to avoid searching in DOM
var content = $('#content');
var input = $('#input');
var status = $('#status');
// my color assigned by the server
var myColor = false;