Skip to content

Instantly share code, notes, and snippets.

View GiancarloJSantos's full-sized avatar

Giancarlo Santos GiancarloJSantos

View GitHub Profile
@levelsio
levelsio / gist:5bc87fd1b1ffbf4a705047bebd9b4790
Last active June 11, 2025 20:57
Secret of Monkey Island: Amsterdam (by @levelsio) or how to create your own ChatGPT image+text-based adventure game
# 2023-11-27 MIT LICENSE
Here's the open source version of my ChatGPT game MonkeyIslandAmsterdam.com.
It's an unofficial image+text-based adventure game edition of Monkey Island in Amsterdam, my home town.
Please use it however you want. It'd be nice to see more ChatGPT-based games appear from this. If you get inspired by it, please link back to my X https://x.com/levelsio or this Gist so more people can do the same!
Send me your ChatGPT text adventure game on X, I'd love to try it!
@jhowbhz
jhowbhz / exemplo_cnpj.html
Last active March 20, 2024 04:47
Busca dados CNPJ APIBRASIL
<!-- COMECE GRATIS AGORA APIBRASIL.COM.BR -->
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/select2.min.css" />
@camilamoreiradev
camilamoreiradev / Scriptcase - Imagem de loading
Created March 7, 2020 20:07
Código para biblioteca interna
<?php
class EmptyClass {}
echo <<<HTML
<style>
.cm_loader {
position: fixed;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
@AndroxxTraxxon
AndroxxTraxxon / MyClass.php
Last active June 18, 2022 09:28
PHP Generic class constructor
<?php
/**
* The important part here isn't the class structure itself, but the
* __construct(...) function. This __construct is generic enough to be placed into any
* data model class that doesn't preprocess its variables,
*
* Even if you want processing on the variables,
* but simply want an initial value from the get-go,
* you can post-process the values after the if($group){...} statement.
*
-> GRID - onRecord
--------------------------------------------------------------------
{wpp} = "<img class='cm_wpp' data-phone='".{telefone}."' data-nome='".{nome}."' data-id='".{id}."' src='/scriptcase9/app/BootstrapTour/_lib/img/grp__NM__ico__NM__if_WhatsApp_1298775.png' border='0'>";
--------------------------------------------------------------------
-> GRID - onScriptInit
@maHostAdmin
maHostAdmin / nginx.site.conf
Created February 16, 2018 17:51
Mautic nginx site conf
server {
listen 80;
listen [::]:80;
# HTTP Authentication on
#include common/acl.conf;
server_name mautic.example.com www.mautic.example.com;
access_log /var/log/nginx/mautic.example.com.access.log rt_cache;
@kekru
kekru / 1-Enable Docker Remote API with TLS client verification.md
Last active May 18, 2025 22:23
Docker Remote API with client verification via daemon.json

Enable Docker Remote API with TLS client verification

Docker's Remote API can be secured via TLS and client certificate verification.
First of all you need a few certificates and keys:

  • CA certificate
  • Server certificate
  • Server key
  • Client certificate
  • Client key

Create certificate files

@deviantony
deviantony / README.md
Last active September 4, 2024 02:41
Portainer HTTP API by example

DEPRECATION NOTICE

This gist is now deprecated in favor of our official documentation: https://documentation.portainer.io/api/api-examples/ which contains up to date examples!

THE FOLLOWING DOCUMENTATION IS DEPRECATED

Please refer to the link above to get access to our updated API documentation and examples.

@rafael-neri
rafael-neri / validar_cpf.php
Last active June 24, 2025 18:14
Validar CPF em PHP (Completo)
<?php
function validaCPF($cpf) {
// Extrai somente os números
$cpf = preg_replace( '/[^0-9]/is', '', $cpf );
// Verifica se foi informado todos os digitos corretamente
if (strlen($cpf) != 11) {
return false;
@ChgoChad
ChgoChad / commands.php
Last active January 5, 2024 22:18 — forked from escopecz/commands.php
Script to run Mautic (https://mautic.org) commands from a URL.
<?php
if (!isset($_GET['ILoveMautic'])) {
echo 'The secret phrase is wrong.';
die;
}
$link = "https://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
$allowedTasks = array(
'cache:clear',