Skip to content

Instantly share code, notes, and snippets.

<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
inquire () {
echo -n "$1 [y/n]? "
read answer
finish="-1"
while [ "$finish" = '-1' ]
do
finish="1"
if [ "$answer" = '' ];
then
answer=""
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>{% block title %}Marketplace - 4Yousee{% endblock %}</title>
<link rel="shortcut icon" type="image/png" href="{{ asset('assets/favicon.png') }}"/>
<link rel="stylesheet" href="{{ asset('build/global.css') }}">
{% block stylesheets %}{% endblock %}
</head>
<body>
server {
listen 80 default;
client_max_body_size 108M;
access_log /var/log/nginx/application.access.log;
root /application/public;
index index.php;
server {
listen 80 default;
client_max_body_size 108M;
#server_name apps.4yousee.com.br;
root /application/public;
#index index.php;
<?PHP
error_reporting(E_ALL);
ini_set('display_errors', 1);
$json = file_get_contents('http://54.213.105.231:8081/pontual/services/TCadastros/GetListaClientes/');
echo "\n<pre>";
print_r(json_decode($json));
echo "\n</pre>";
@samhk222
samhk222 / 01 Clone repo
Last active December 11, 2018 12:29
Aia.la Docker Compose
git clone https://github.com/samhk222/Docker-LAMP-Boilerplate
@samhk222
samhk222 / 01 - Requerendo o pacote
Last active December 12, 2018 01:45
Blog - Post sobre variáveis .env
composer require vlucas/phpdotenv
import React, {Component} from 'react';
import {
StyleSheet,
Text,
Platform,
View,
Alert} from 'react-native';
import { TOKEN_SAMUCA } from 'react-native-dotenv'
import api from './services/api'
@samhk222
samhk222 / Parser.php
Last active December 27, 2018 13:14
Create a composer package
<?PHP
# Lembra quando fizemos o autoload dentro do composer.json, para os namespaces samhk222 dentro da pasta src ?
# precisamos declará-lo agora, senão não sera feito o autload dessa classe
namespace samhk222;
class Parser
{
public $hasJSON = false; #Indica se a string tem algum json
public $hasFaltyJSON = false; # Indica se tem json, mas com erro
public $matches = []; # Retorna os matches do json caso encontrados