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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
# | |
# Criado originalmente po Arthur Furlan - http://arthurfurlan.org/ | |
from fabric.api import * | |
env.hosts = ['user@host'] | |
env.path = '/home/user_path/public_html' |
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 | |
echo date('m', strtotime('-3month')); |
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 | |
App::uses('AppModel', 'Model'); | |
/** | |
* User Model | |
* | |
* @property Group $Group | |
*/ | |
class User extends AppModel { | |
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
# /etc/X11/xorg.conf (Xorg X Window System server configuration file) | |
# | |
# This file was generated by fll_xorgconfig, the F.U.L.L.S.T.O.R.Y. | |
# Xorg Configuration tool. | |
# | |
# Edit this file with caution, and see the xorg.conf(5) manual page. | |
# (Type "man xorg.conf" at the shell prompt.) | |
Section "ServerLayout" | |
Identifier "Xorg Configured" |
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 | |
/** | |
* This is the PHP base ACL configuration file. | |
* | |
* Use it to configure access control of your Cake application. | |
* | |
* PHP 5 | |
* | |
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org) | |
* Copyright 2005-2012, Cake Software Foundation, Inc. (http://cakefoundation.org) |
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 | |
// $q variable | |
WP_Query Object | |
( | |
[query] => Array | |
( | |
[post_type] => product | |
) | |
[query_vars] => Array |
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 | |
App::uses('AppController', 'Controller'); | |
/** | |
* Usuarios Controller | |
* | |
* @property Usuario $Usuario | |
*/ | |
class UsuariosController extends AppController { |
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 | |
App::uses('AppController', 'Controller'); | |
class UsuariosController extends AppController { | |
public function login() { | |
if ($this->request->is('post')) { | |
if ($this->Auth->login()) { | |
$this->redirect($this->Auth->redirectUrl()); |
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 | |
// código de sua View | |
echo $this->Form->input('email.'); | |
// importantíssimo existir o ponto após o nome do campo, ele quem determinará que é um array | |
// código do Controller |