Skip to content

Instantly share code, notes, and snippets.

View marcopin's full-sized avatar

Marco Pinero marcopin

View GitHub Profile
@marcopin
marcopin / BrowserDetectProtocol.js
Created September 8, 2022 20:47 — forked from rajeshsegu/BrowserDetectProtocol.js
Detect Browser Custom Protocols
<html>
<head>
<title>Detect Custome Protocol</title>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.1.min.js"></script>
</head>
<body>
<input id="protocol" value="" placeholder="custom protocol"/>
<button id="launch">Launch</button>
<!-- Mozilla Only -->
<iframe id="hiddenIframe" src="about:blank" style="display:none"></iframe>
@marcopin
marcopin / pause.bat
Created July 2, 2015 20:26
Windows/DOS/cmd: Pause batch executon n-milliseconds before continue
ping 1.1.1.1 -n 1 -w [millisecods] > nul
@marcopin
marcopin / runmultiple.sh
Created July 2, 2015 20:24
Linux bash: Execute same command for multiple files
find <folderpath> -name <filemask> -exec <command> <extra parameters> {} \;
@marcopin
marcopin / playsndmemorystream.pas
Created July 2, 2015 20:22
Delphi: Play sound from memorystream
var
Form1: TForm1;
ms: TMemoryStream;
:
procedure PlayWaveStream(Stream: TMemoryStream);
begin
if Stream = nil then
sndPlaySound(nil, SND_ASYNC) //stop sound