Skip to content

Instantly share code, notes, and snippets.

@scriptdev
scriptdev / .php
Created July 26, 2021 18:52
FORMATA TEXTO COM ACENTUAÇÃO NO PDF
<?php
$cidade = utf8_decode('João Pessoa');
@scriptdev
scriptdev / .php
Created July 26, 2021 18:54
DATA DE HOJE
<?php
$data_hoje = TDate::date2br(date('Y-m-d'));
// RETORNO: 01/01/2021
@aamiaa
aamiaa / CompleteMokokoQuest.md
Last active April 19, 2024 15:06
Complete Discord Mokoko Quest

Complete Discord Mokoko Quest

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
  2. Join a vc
  3. Stream any window (can be notepad or something)
  4. Press Ctrl+Shift+I to open DevTools
  5. Go to the Console tab
  6. Paste the following code and hit enter:
let wpRequire;
@scriptdev
scriptdev / .php
Last active April 19, 2024 15:05
GRÁFICO DE COLUNAS "BarChart" COM VALORES FORMATADOS EM REAIS
/*
1° - CRIAÇÃO DO ARQUIVO HTML DO GRÁFICO DE COLUNAS "BarChart".
CRIE O ARQUIVO HTML COM O NOME DESEJADO.. OBS: JÁ EXISTE POR PADRÃO
O ARQUIVO google_bar_chart.html NO PROJETO DO ADIANTI.
O OBJETIVO É PERSONALIZAR O CÓDIGO PARA DEFINIR A FORMATAÇÃO DOS
VALORES DO GRÁFICO EM REAIS "EXEMPLO: R$ 1.500,00"
COMO EXEMPLO.. VOU CRIAR O ARQUIVO COM O NOME: grafico_coluna_google.html
*/
@scriptdev
scriptdev / .php
Created July 27, 2021 01:21
DESABILITAR ABERTURA AUTOMÁTICA DO CALENDÁRIO NO CAMPO TDate
<?php
$data_nascimento->setOption('showOnFocus', false);
@Ravenstine
Ravenstine / aws-couchdb-setup.md
Last active April 19, 2024 15:03
Fast CouchDB setup in AWS

Fast CouchDB setup in AWS

CouchDB is a NoSQL database for storing JSON documents. It comes with a REST API out of the box so your client applications can persist data while requiring you to write little or no server-side code. CouchDB's killer feature is its ability to easily replicate, which allows for horizontal scaling, easy backup, and for client adapters to synchronize documents. This is perfect if you want to write an application that is offline-first. It's become my go-to database when creating new

@AaradhyaSaxena
AaradhyaSaxena / 00-Introduction.md
Last active April 19, 2024 15:03
Introduction to Information Retrieval

These are my notes from the book "Introduction to information retrieval"

  1. Intro to IR
  2. Term Vocabulary
  3. Tolerant Retrieval
  4. Index Construction
  5. Index Compression
  6. Scoring
  7. Compute Scoring
  8. Evaluation of Information Retrieval
@scriptdev
scriptdev / .php
Last active April 19, 2024 15:03
TAlert NOTIFICAÇÃO DO BOOTSTRAP
<?php
$this->element_mensagem->add(new TAlert('danger', 'ATENÇÃO! INFORME O CPF!'));
@steveosoule
steveosoule / wget--crawl.sh
Created May 31, 2017 17:05
Wget - Options & Sample Crawler
#!/bin/sh
# wget --mirror --adjust-extension --page-requisites --execute robots=off --wait=30 --rand om-wait --convert-links --user-agent=Mozilla http://www.example.com
### V1
# wget \
# --recursive \
# --no-clobber \
# --page-requisites \
# --html-extension \
@scriptdev
scriptdev / .php
Last active April 19, 2024 15:03
FILTRO LIMIT NO GRÁFICO BPieChart
<?php
$grafico = new BBarChart('grafico');
$table = new BTableChart('table');
# EXEMPLO COM O BBarChart
$criteria_grafico = new TCriteria;
$criteria->setProperty('limit', 5);
$criteria->setProperty('order', 'id desc');
# $criteria->setProperty('direction', 'desc');