Skip to content

Instantly share code, notes, and snippets.

View SantosJMM's full-sized avatar
🏠
Working from home

Santos Junior Marte Marte SantosJMM

🏠
Working from home
View GitHub Profile
@SantosJMM
SantosJMM / db-connect-test.php
Created November 1, 2017 04:33 — forked from M165437/db-connect-test.php
Script for a quick PHP MySQL DB connection test.
<?php
# Fill our vars and run on cli
# $ php -f db-connect-test.php
$dbname = 'name';
$dbuser = 'user';
$dbpass = 'pass';
$dbhost = 'host';
$link = mysqli_connect($dbhost, $dbuser, $dbpass) or die("Unable to Connect to '$dbhost'");
@SantosJMM
SantosJMM / README.md
Created November 20, 2018 12:27 — forked from nitaku/README.md
Minimal JSON HTTP server in python

A minimal HTTP server in python. It sends a JSON Hello World for GET requests, and echoes back JSON for POST requests.

python server.py 8009
Starting httpd on port 8009...
curl http://localhost:8009
{"received": "ok", "hello": "world"}
@SantosJMM
SantosJMM / README.md
Created March 22, 2021 01:19 — forked from collinxsmith1/README.md
Evaluation of PySide2 GUI Program code base
@SantosJMM
SantosJMM / example_model.py
Created January 23, 2022 13:46 — forked from danmana/example_model.py
Add support for custom json fields in Odoo
from odoo import models, fields, api
from json_field import JsonField
class Person(models.Model):
_name = 'example.person'
_description = 'Person with json details'
details = JsonField() # a json object represented as dict / list / python primitives
'''
Project: curinga
Time: 2020/03/07 01:37
'''
import win32api
import win32print
import traceback
from tkinter.filedialog import askopenfilename
from tkinter import *