Skip to content

Instantly share code, notes, and snippets.

Avatar
🎯
Focusing

Dario Garcia dario61081

🎯
Focusing
View GitHub Profile
View export_csv.php
<?php
include_once implode(DIRECTORY_SEPARATOR, [__DIR__, 'conector.inc.php']);
const debug=true;
$format=$_GET['format']??'json';
if (debug){
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
}
@dario61081
dario61081 / conexion.py
Created Apr 20, 2019
Clase para conexion con base de datos OpenSource MIT
View conexion.py
#!/usr/bin/python
# Libreria de conexion a base de datos
# Autor: Dario R. Garcia G. DR2GSistemas
# Villeta - Paraguay
#
# Version: 1.02
# - Agregado runtime exception
# Version: 1.01
# - Bug fix: control de host y port
# Version: 1.00
@dario61081
dario61081 / select_in_list.sql
Created Jul 29, 2018
Seleccionando items de una tabla contra una lista subselect. (firebird)
View select_in_list.sql
-- seleccionando items de una tabla contra una lista subselect (firebird).
select p.categoria, t.sub_categoria,0 monto
from pagos p, (select distinct pp.sub_categoria from pagos pp) t
group by 1,2
-- dataset --
-- categoria: 7,8,9
-- sub categoria: a,b,c,d,e
@styblope
styblope / docker-api-port.md
Last active Jun 22, 2021
Enable TCP port 2375 for external connection to Docker
View docker-api-port.md

Enable TCP port 2375 for external connection to Docker

See this issue.
Docker best practise to Control and configure Docker with systemd.

  1. Create daemon.json file in /etc/docker:

     {"hosts": ["tcp://0.0.0.0:2375", "unix:///var/run/docker.sock"]}
    
@alphamu
alphamu / Android Privacy Policy Template
Created Feb 9, 2017
A template for creating your own privacy policy for Android apps. Look for "[" and "<!--" to see where you need to edit this app in order to create your own privacy olicy.
View Android Privacy Policy Template
<html>
<body>
<h2>Privacy Policy</h2>
<p>[Individual or Company Name] built the [App Name] app as a [open source | free | freemium | ad-supported | commercial] app. This SERVICE is provided by [Individual or company name] [at no cost] and is intended
for use as is.</p>
<p>This page is used to inform website visitors regarding [my|our] policies with the collection, use, and
disclosure of Personal Information if anyone decided to use [my|our] Service.</p>
<p>If you choose to use [my|our] Service, then you agree to the collection and use of information in
relation with this policy. The Personal Information that [I|we] collect are used for providing and
improving the Service. [I|We] will not use or share your information with anyone except as described
@efrenfuentes
efrenfuentes / numero_letras.py
Created Sep 26, 2012
Numero a letras (Python)
View numero_letras.py
#!/usr/bin/python
# -*- coding: utf-8 -*-
__author__ = 'efrenfuentes'
MONEDA_SINGULAR = 'bolivar'
MONEDA_PLURAL = 'bolivares'
CENTIMOS_SINGULAR = 'centimo'