Skip to content

Instantly share code, notes, and snippets.

@Maasik
Maasik / autosave.js
Created November 6, 2021 17:09 — forked from gcmurphy/autosave.js
Very simple autosave functionality using local storage
var AutoSave = (function(){
var timer = null;
function getEditor(){
var elems = document.getElementsByTagName("textarea")
if (elems.length <= 0)
return null;
@Maasik
Maasik / gist:d3f6ff74f1ef93914460579099f02c7a
Created April 27, 2017 08:29 — forked from simshaun/gist:7592631
TinyMCE 4.0.11 - Automatically remove width and height attributes from img elements inserted via the img plugin
setup: function (editor) {
editor.on('init', function(args) {
editor = args.target;
editor.on('NodeChange', function(e) {
if (e && e.element.nodeName.toLowerCase() == 'img') {
tinyMCE.DOM.setAttribs(e.element, {'width': null, 'height': null});
}
});
}
@Maasik
Maasik / index.html
Created November 11, 2016 20:43 — forked from anonymous/index.html
Capture FB Reactions count and show them on webpage
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>My FB Reactions Page</title>
<style>
html {
box-sizing: border-box;
width: 100%;
@Maasik
Maasik / index.html
Created November 11, 2016 16:50 — forked from anonymous/index.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Elections 2016</title>
<style>
html {
box-sizing: border-box;
}
*, *:before, *:after {
@Maasik
Maasik / gpoint.php
Created May 31, 2016 19:12 — forked from cypres/gpoint.php
PHP class to convert Latitude & Longitude coordinates into UTM & Lambert Conic Conformal Northing/Easting coordinates.
<?php
/**
* PHP class to convert Latitude & Longitude coordinates into UTM & Lambert Conic Conformal Northing/Easting coordinates.
*
* This class encapsulates the methods for representing a geographic point on the earth in three different coordinate systema. Lat/Long, UTM and Lambert Conic Conformal.
*
* Code for datum and UTM conversion was converted from C++ code written by Chuck Gantz ([email protected]) from http://www.gpsy.com/gpsinfo/geotoutm/
* This code was converted into PHP by Brenor Brophy ([email protected]) and later refactored for PHP 5.3 by Hans Duedal ([email protected]).
*
<?php
/**
* @example
* $htmlRenderer = new HtmlRenderer();
* $consoleRenderer = new ConsoleRenderer();
* $htmlRenderer->renderToFile($view, 'some.html', [ TableRendererInterface::STREAMED ]);
* echo $consoleRenderer->renderToString($profilingView);
*/
interface TableRendererInterface
<?php
/*
=====================================================
n0wheremany
-----------------------------------------------------
http://nowheredev.ru/
-----------------------------------------------------
Copyright (c) 2013 n0wheremany
=====================================================
Данный код защищен авторскими правами