Skip to content

Instantly share code, notes, and snippets.

View myselfsufiyan's full-sized avatar
💻
I Love My Work

Muhammad Sufian myselfsufiyan

💻
I Love My Work
View GitHub Profile
@myselfsufiyan
myselfsufiyan / bash-colors.md
Created January 30, 2024 06:53 — forked from JBlond/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@myselfsufiyan
myselfsufiyan / hosted_example.txt
Created November 2, 2020 16:12 — forked from makevoid/hosted_example.txt
JQuery DOM HighLighter (it's a basic "Inspect element" simple implementation to mimic what webkit inspector and firebug do)
http://uploads.makevoid.com/jquery_dom_highlighter.html
@myselfsufiyan
myselfsufiyan / DistanceCalculator.java
Created May 28, 2019 11:13 — forked from danielgomezrico/DistanceCalculator.java
Java / Android - calculate the distance between two coordinates with great circle formula.
import static java.lang.Math.acos;
import static java.lang.Math.cos;
import static java.lang.Math.sin;
/**
* Calculate distance between coordinates.
*/
public class DistanceCalculator {
static double PI_RAD = Math.PI / 180.0;
@myselfsufiyan
myselfsufiyan / .php
Last active January 4, 2016 08:58 — forked from 0xnbk/.php
<?php
// place this code inside a php file and call it f.e. "download.php"
$path = $_SERVER['DOCUMENT_ROOT']."/path2file/"; // change the path to fit your websites document structure
$fullPath = $path.$_GET['download_file'];
if ($fd = fopen ($fullPath, "r")) {
$fsize = filesize($fullPath);
$path_parts = pathinfo($fullPath);
$ext = strtolower($path_parts["extension"]);