Skip to content

Instantly share code, notes, and snippets.

View marcaum54's full-sized avatar

Marcos Fábio dos Santos Amaral Júnior marcaum54

View GitHub Profile
$('#mc-form').validate({
highlight: function(element, errorClass) {
$(element).fadeOut(function() {
$(element).fadeIn();
});
},
rules: {
name: {
required: true,
minlength: 2
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) {
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
(
@marcaum54
marcaum54 / fortes_meeting
Last active August 29, 2015 14:01
HTML do Email Marketing
<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;">
<?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');
<?php
$pathCsv = __DIR__ . '/arquivos/';
$arquivos = array(
'contas1.csv',
'contas2.csv'
);
$rows = array();
@marcaum54
marcaum54 / gist:6716659
Created September 26, 2013 16:30
Esse foi o resultado me retornado passando os seguintes parametros: $Tipo = 'P' $SiteId = 35
Array
(
[0] => stdClass Object
(
[Tipo] => P
[Id] => 1535
[Nome] => Exame de Ordem - Administrativo Completo
[Valor] => 389,00
[Objetivo] => <p>&lt;p&gt;a&lt;/p&gt;</p>
[Temas] => <p>&lt;p&gt;a&lt;/p&gt;</p>
<?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/';