This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//72F82C4B0CBCC1704CDD2130E685E767 | |
class Dota2_API | |
{ | |
protected $_apiKey; | |
const HEROES_NAME_PREFIX = 'npc_dota_hero_'; | |
const URL_GETHEROES = 'https://api.steampowered.com/IEconDOTA2_570/GetHeroes/v0001/'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Array | |
( | |
[0] => stdClass Object | |
( | |
[Tipo] => P | |
[Id] => 1535 | |
[Nome] => Exame de Ordem - Administrativo Completo | |
[Valor] => 389,00 | |
[Objetivo] => <p><p>a</p></p> | |
[Temas] => <p><p>a</p></p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$pathCsv = __DIR__ . '/arquivos/'; | |
$arquivos = array( | |
'contas1.csv', | |
'contas2.csv' | |
); | |
$rows = array(); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
try | |
{ | |
$x = new SoapClient((string)$this->url); | |
} | |
catch (SoapFault $e) | |
{ | |
$this->setMessage('Servidor Indisponivel. Por favor, entre em contato com nosso setor financeiro.'); | |
$this->setRedirect('index.php?option=com_ag&view=login'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head><title></title></head> | |
<body style="background-color: #FFF;"> | |
<table style="margin: 0 auto; width: 600px; border:0; border-collapse: collapse;" cellpadding="0" cellspacing="0"> | |
<tbody> | |
<tr> | |
<td><img src="http://fortesinformatica.com.br/v3/i/newsletters/2014/fortes_meeting/bg-01.png" /></td> | |
</tr> | |
<tr> | |
<td align="center" valign="middle" style="height: 80px;"> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ERROR | NASH - Contas a Receber - Dados: Informação fornecida pelo NASH - Status: '3' | Erros: Array | |
( | |
[0] => | |
) | |
Contas a Receber: ContaAReceber Object | |
( | |
[Empresa] => | |
[Cliente] => Cliente Object | |
( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protected function get400() { | |
$content = $this->getHttpObject()->getContent(); | |
$erros = json_decode($content, true); | |
$erro = array(); | |
if (is_array($erros)) { | |
if (key_exists("Erros", $erros) && is_array($erros["Erros"])){ | |
foreach ($erros["Erros"] as $key => $value) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('#mc-form').validate({ | |
highlight: function(element, errorClass) { | |
$(element).fadeOut(function() { | |
$(element).fadeIn(); | |
}); | |
}, | |
rules: { | |
name: { | |
required: true, | |
minlength: 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Since I was looking all around how to uninstall packages and after reading tones | |
of documentations here's the short how-to uninstall a workbench package in Laravel | |
(or how I managed it to work out): | |
1. Remove package service provider from 'providers' array in app/config/app.php | |
2. Remove the package folder in workbench/ | |
3. Run: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$examples = [ | |
'cpf' => [ 'regex:/^\d{3}.\d{3}.\d{3}-\d{2}$/' ], | |
'cnpj' => [ 'regex:/^\d{2}.\d{3}.\d{3}\/\d{4}-\d{2}$/' ], | |
'telefone' => [ 'regex:/^\(\d{2}\) \d{4}-\d{4,5}$/' ], | |
'cep' => [ 'regex:/^\d{5}-\d{3}$/' ], | |
]; |
OlderNewer