This file contains hidden or 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
sudo apt-get install apache2 apache2-mpm-prefork apache2.2-bin apache2.2-common libaio1 libapache2-mod-php5 libaprutil1-dbd-sqlite3 libaprutil1-ldap libc-client2007e libdbd-mysql-perl libdbi-perl libhtml-template-perl libmcrypt4 libming1 libmysqlclient18 libnet-daemon-perl libplrpc-perl librecode0 libterm-readkey-perl libtidy-0.99-0 mlock mysql-client mysql-client-5.5 mysql-client-core-5.5 mysql-common mysql-server mysql-server-5.5 mysql-server-core-5.5 php-pear php5 php5-cli php5-common php5-curl php5-gd php5-imagick php5-imap php5-intl php5-mcrypt php5-memcache php5-ming php5-mysql php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xsl pslib1 |
This file contains hidden or 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
//Function que cria o Dialog | |
function inputDialog(textop, callback){ | |
apprise(textop, {'input': true,'textOk':'Enviar'}, function(r) { | |
callback(r); | |
}); | |
} | |
//Plugin necessário (junto com o jQuery) | |
function apprise(string,args,callback) | |
{var default_args={'confirm':false,'verify':false,'input':false,'animate':false,'textOk':'Ok','textCancel':'Cancel','textYes':'Yes','textNo':'No'} |
This file contains hidden or 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
<div class="btn-group"> | |
<a class="btn dropdown-toggle" data-toggle="dropdown" href="#"> | |
Ações | |
<span class="caret"></span> | |
</a> | |
<ul class="dropdown-menu"> | |
<?php if(in_array($nota['Nfe']['infProt_cStat'], $cStat)){ ?> | |
<li class="xml"><a href="/sistema/emissor/notas/consulta/<?php echo $nota['Nfe']['id'] ?>" class="context">Atualizar</a></li> | |
<?php } ?> | |
<li class="danfe"><a href="/sistema/emissor/notas/danfe/<?php echo $nota['Nfe']['id'] ?>" class="context">DANFE</a></li> |
This file contains hidden or 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
<!--VIEW--> | |
<div class="notas all"> | |
<?php | |
echo $this->Html->script(array('mask')); | |
echo $this->Html->script(array('jquery.contextMenu')); | |
echo $this->Html->css(array('jquery.contextMenu')); | |
?> | |
<script> | |
function Mask(){ | |
$(".CPF").mask("999.999.999-99"); |
This file contains hidden or 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 | |
class NfesController extends ArmazenamentoAppController{ | |
public $components = array( | |
'Emissor.NFePHP', | |
'Emissor.MailNFePHP', | |
); | |
public function enviaTeste(){ |
This file contains hidden or 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
algoritmo "exercicio5" | |
Var | |
N1,N2: inteiro | |
Media,Produto,Quociente,Diferenca,Resto: real | |
inicio | |
escreval ("escreva dois numeros") | |
leia (N1) | |
leia (N2) | |
Media<-(N1+N2)/2 |
This file contains hidden or 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 | |
$songs = array( | |
'1' => array('artist'=>'The Smashing Pumpkins', 'songname'=>'Soma'), | |
'2' => array('artist'=>'The Decemberists', 'songname'=>'The Island'), | |
'3' => array('artist'=>'Fleetwood Mac', 'songname' =>'Second-hand News') | |
); | |
function subval_sort($a,$subkey) { | |
foreach($a as $k=>$v) { | |
$b[$k] = strtolower($v[$subkey]); |
This file contains hidden or 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 | |
$feed = file_get_contents('http://feeds2.feedburner.com/ThiagoBelem/Blog'); | |
$rss = new SimpleXmlElement($feed); | |
foreach($rss->channel->item as $entrada) { | |
echo '<p><a href="' . $entrada->link . '" title="' . $entrada->title . '">' . $entrada->title . '</a></p>'; | |
} | |
?> |
This file contains hidden or 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 | |
$arquivo = fopen('testes.txt', 'r'); | |
if(!$arquivo){ | |
echo 'Não foi possível abrir o arquivo'; | |
} | |
else{ | |
while(!feof($arquivo)){ | |
$linha = fgets($arquivo); | |
echo rtrim($linha) . "<br>"; |
This file contains hidden or 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
$(document).ready(function(){ | |
var keys = []; | |
var konami = '38,38,40,40,37,39,37,39,66,65'; | |
$(document) | |
.keydown( | |
function(e) { | |
keys.push( e.keyCode ); | |
if ( keys.toString().indexOf( konami ) >= 0 ){ | |