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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, | |
# please see the online documentation at vagrantup.com. |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.box = 'precise64' | |
config.vm.box_url = 'http://files.vagrantup.com/precise64.box' | |
config.vm.hostname = 'devbox' | |
config.vm.synced_folder ".", "/Projects", id: "vagrant-root" |
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
{12-10-03 13:23}vps:~ carcia% which rails | |
rails not found | |
{12-10-03 13:30}vps:~ carcia% curl -L https://get.rvm.io | bash -s stable --ruby | |
% Total % Received % Xferd Average Speed Time Time Time Current | |
Dload Upload Total Spent Left Speed | |
100 10009 100 10009 0 0 10348 0 --:--:-- --:--:-- --:--:-- 89366 | |
Please read and follow further instructions. | |
Press ENTER to continue. | |
Downloading RVM from wayneeseguin branch stable | |
% Total % Received % Xferd Average Speed Time Time Time Current |
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 | |
//------------------------------------|| RESIZE BASIC ||---------------------------------- | |
require_once 'includes/thumb/ThumbLib.inc.php'; | |
//Recebe parametros | |
$img = $_GET['img']; | |
$wi = $_GET['width']; | |
$he = $_GET['height']; | |
//Cria imagem |
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
<div id="work"> | |
<ul class="thumbnails"> | |
<?php $loop = new WP_Query( array( 'post_type' => 'work', 'posts_per_page' => 9 ) ); ?> | |
<?php $i = 0; // starts the counter ?> | |
<?php while ( $loop->have_posts() ) : $loop->the_post(); ?> | |
<?php if ($i % 3 == 0 ) { | |
echo '<li class="span4" style="clear:left;">'; // clear left if start of new row. | |
} else { | |
echo '<li class="span4">'; // continuation of a row, no need to clear left. |
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
defaults: &DEFAULTS | |
adapter: mysql2 | |
encoding: utf8 | |
reconnect: true | |
pool: 5 | |
host: localhost | |
username: railsSQL | |
password: senhadomysql | |
development: |
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
#!/bin/env ruby | |
# encoding: utf-8 | |
################################################################################################## | |
source 'https://rubygems.org' | |
################################################################################################## | |
gem 'rails', '3.2.8' | |
gem 'mysql2' | |
gem 'thin' | |
gem 'twitter-bootstrap-rails' | |
gem 'brazilian-rails' |
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
source 'https://rubygems.org' | |
gem 'rails', '3.2.10' | |
gem 'mysql2' | |
group :assets do | |
gem 'sass-rails', '~> 3.2.3' | |
gem 'coffee-rails', '~> 3.2.1' |
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
class CreateDetalhes < ActiveRecord::Migration | |
def change | |
create_table :detalhes do |t| | |
t.references :veiculo | |
t.references :user | |
# CONFORTO DO VEÍCULO CARRO | |
t.boolean :abertura_interna_do_porta_malas | |
t.boolean :ar_condicionado |
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
#!/bin/env ruby | |
# encoding: utf-8 | |
class ApplicationController < ActionController::Base | |
protect_from_forgery | |
def after_sign_in_path_for(resource) | |
inicio_path | |
end | |
def after_sign_out_path_for(resource) | |
inicio_path | |
end |
OlderNewer