Skip to content

Instantly share code, notes, and snippets.

View HNJAMeindersma's full-sized avatar

Rick HNJAMeindersma

View GitHub Profile
@mdonkers
mdonkers / server.py
Last active July 22, 2024 13:51
Simple Python 3 HTTP server for logging all GET and POST requests
#!/usr/bin/env python3
"""
License: MIT License
Copyright (c) 2023 Miel Donkers
Very simple HTTP server in python for logging requests
Usage::
./server.py [<port>]
"""
from http.server import BaseHTTPRequestHandler, HTTPServer
@sepehr
sepehr / csv_parse.php
Created September 12, 2012 14:35
PHP: Parse CSV into Keyed Array
<?php
/**
* Parses CSV file into an associative array with the first row as field names.
*
* @param string $filepath Path to readable CSV file.
* @param array $options Parse options (eol, delimiter, enclosure, escape, to_object).
*
* @return array Associative array of parsed CSV file.
*/