| layout | post | ||
|---|---|---|---|
| title | Olá, mundo! | ||
| date | 2012-07-14 13:19 | ||
| comments | true | ||
| categories |
|
Opa, galera, beleza? Esse é o primeiro post aqui no meu blog. Estou usando o Octopress, falarei aqui também sobre ele.
| <?php | |
| class AppModel extends Model { | |
| public function retornaErro(){ | |
| $db = ConnectionManager::getDataSource('default'); | |
| return $db->lastError(); | |
| } | |
| } |
| var line = new RGraph.Line('chart1', charts.data); | |
| line.Set('chart.labels', this.labels); | |
| line.Set('chart.linewidth', 3); | |
| line.Set('chart.key', charts.keys); | |
| line.Set('chart.colors', charts.colors); | |
| line.Set('chart.contextmenu', [ | |
| ['Zoom', RGraph.Zoom], | |
| ['Edit', function(){ | |
| RGraph.Reset( line.canvas ); | |
| RGraph.Clear( line.canvas ); |
| <?php | |
| class InscricoesController extends AppController { | |
| //seus códigos | |
| ... | |
| public function inscricao (){ | |
| $tipos = $this->Inscricao->Tipo->find('list'); | |
| $this->set(compact('tipos')); |
| Ext.define('MyApp.store.Users', { | |
| extend: 'Ext.data.Store', | |
| requires: ['MyApp.model.User'], | |
| model: 'MyApp.model.User', | |
| storeId: 'Users', | |
| autoLoad: true, | |
| proxy: { | |
| type: 'ajax', | |
| url: 'php/users/index.json', | |
| reader: { |
| layout | post | ||
|---|---|---|---|
| title | Olá, mundo! | ||
| date | 2012-07-14 13:19 | ||
| comments | true | ||
| categories |
|
Opa, galera, beleza? Esse é o primeiro post aqui no meu blog. Estou usando o Octopress, falarei aqui também sobre ele.
| <?php | |
| /** | |
| * BancoDeDados | |
| * | |
| * Essa classe estabelece uma conexão com o banco de dados e também | |
| * é responsável por fechar essa conexão. Nessa classe também é possível forçar uma nova conexão. | |
| * | |
| * @author Luiz Messias <tonyzrp@gmail.com> | |
| * | |
| */ |
| <?php | |
| // first route | |
| Router::connect( | |
| '/:slug', | |
| array( | |
| 'controller' => 'Startups', | |
| 'action' => 'view' | |
| ), | |
| array( | |
| 'slug' => '[0-9A-Za-z_-]+Startup', //just an example |
| <html> | |
| <head> | |
| <title>Test rgraph</title> | |
| <script type="text/javascript" src="rgraph/RGraph.common.core.js" ></script> | |
| <script type="text/javascript" src="rgraph/RGraph.common.dynamic.js" ></script> | |
| <script type="text/javascript" src="rgraph/RGraph.bar.js" ></script> | |
| <script type="text/javascript" src="rgraph/RGraph.line.js" ></script> | |
| <script type="text/javascript"> | |
| window.onload = function () |
| <!doctype html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>JS Validation</title> | |
| <script src="jsvalidation.js"></script> | |
| </head> | |
| <body> | |
| <h1>Validação de números</h1> | |
| <p>Detalhe: não é possível também copiar e colar strings no campo, apenas números</p> |
| <?php | |
| /** | |
| * Controller de usuários | |
| */ | |
| class UsuariosController extends AppController | |
| { | |
| public function index() | |
| { | |
| if(isset($this->request->data) && $this->request->is('post')) { |