Skip to content

Instantly share code, notes, and snippets.

View MaxDragonheart's full-sized avatar

Massimiliano Moraca MaxDragonheart

View GitHub Profile
@MaxDragonheart
MaxDragonheart / timeofreading.py
Created April 20, 2020 07:41
Script for count reading time of a text
from datetime import datetime
from bs4 import BeautifulSoup
###### START CODE!!!! :)
###### Python3
###### E' possibile leggere 200 parole al minuto
def choice_zero():
print('\n>>>>>RESPONSE')
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@MaxDragonheart
MaxDragonheart / download-site-path.py
Created April 20, 2020 07:45
Script for download the list of public urls from a website
from datetime import datetime
from urllib.request import urlopen
import re
########################Python 3.6.7
def choice_one():
'''
This function write the urls into a txt file
'''
/* INDEX */
/* 1 - Generic customizations */
/* ######################## */
/* 1 - Generic customizations */
html, body, section {
margin: 0;
@MaxDragonheart
MaxDragonheart / 1-quick-start.js
Last active January 3, 2021 08:49
Code for DirectOpenLayers
import './style.css';
import {MapInizialized, MapSetView, BaseMapLayer} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(0.0, 0.0, 0);
const basemap = new BaseMapLayer('OSM');
const osm = basemap.createOSMStandard();
mapCanvas.addLayer(osm);
@MaxDragonheart
MaxDragonheart / 2-fullscreen-and-scaleline.js
Created January 3, 2021 09:08
Code for DirectOpenLayers
import './style.css';
import {
MapInizialized, MapSetView, BaseMapLayer,
MapFullScreen, MapScaleLine
} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(0.0, 0.0, 0);
const fullScreen = new MapFullScreen();
const scaleLine = new MapScaleLine();
@MaxDragonheart
MaxDragonheart / 3-add-vectors.js
Last active January 3, 2021 09:28
Code for DirectOpenLayers
import './style.css';
import {
MapInizialized, MapSetView, BaseMapLayer,
MapScaleLine, MapFullScreen, vectorsLayer
} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(14.350, 40.905, 15);
const scaleLine = new MapScaleLine();
const basemap = new BaseMapLayer('OSM');
@MaxDragonheart
MaxDragonheart / 4-zoom-on-vector-source.js
Created January 3, 2021 09:39
Code for DirectOpenLayers
import './style.css';
import {
MapInizialized, MapSetView, BaseMapLayer,
MapFullScreen, MapScaleLine, vectorsLayer
} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(14.350, 40.905, 5);
const basemap = new BaseMapLayer('Test');
const osm = basemap.createOSMStandard();
@MaxDragonheart
MaxDragonheart / 5-lock-to-extent.js
Created January 3, 2021 18:11
Code for DirectOpenLayers
import './style.css';
import {
MapInizialized, MapSetView, BaseMapLayer,
MapFullScreen, MapScaleLine, vectorsLayer
} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(14.350, 40.905, 5);
const basemap = new BaseMapLayer('Test');
const osm = basemap.createOSMStandard();
@MaxDragonheart
MaxDragonheart / 6-points-clusters.js
Created January 3, 2021 20:02
Code for DirectOpenLayers
import './style.css';
import {
MapInizialized, MapSetView, BaseMapLayer,
MapFullScreen, MapScaleLine, vectorsLayer
} from './directopenlayers';
const mapCanvas = new MapInizialized('map');
const mapCanvasView = new MapSetView(14.350, 40.905, 3);
const basemap = new BaseMapLayer('OSM');
const osm = basemap.createOSMStandard();