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
| mkdir /usr/local/src | |
| cd /usr/local/src | |
| wget url-for-latest-postgres-package | |
| tar xzf postgres...tgz | |
| cd postgres... | |
| ./configure --with-bonjour --with-openssl | |
| ./make | |
| ./make install |
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
| # run psql as the postgres user | |
| psql -U postgres | |
| create role USERNAME with createdb login; | |
| \q | |
| # run psql as the newly created user | |
| psql -U USERNAME postgres | |
| create database DBNAME; | |
| \q |
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
| # you can trap for nil entries in validations and validations are simple | |
| # you can always test it with .blank? | |
| # you can always convert nil values to empty strings by simply | |
| # adding .to_s | |
| # i.e. | |
| test = User.new | |
| test.name | |
| => nil | |
| test.name.to_s | |
| => "" |
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
| <!-- add the following code to your functions.php file --> | |
| <?php | |
| add_filter( 'sidebars_widgets', 'disable_all_widgets' ); | |
| function disable_all_widgets( $sidebars_widgets ) { | |
| if ( is_home() ) | |
| $sidebars_widgets = array( false ); | |
| return $sidebars_widgets; | |
| } |
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 // get the value of "variable" from the URL | |
| $val = $_GET['variable']; | |
| ?> | |
| <?php | |
| if ( $val == "yeah" ) { | |
| echo "the variable is YEAH!"; | |
| } ?> | |
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
| require 'capistrano/recipes/deploy/strategy/base' | |
| require 'fileutils' | |
| require 'tempfile' # Dir.tmpdir | |
| require 'net/ssh' | |
| require 'net/sftp' | |
| require 'find' | |
| module Capistrano | |
| module Deploy |
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="single"> | |
| <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur sit amet suscipit mi. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus mollis, justo sit amet fringilla laoreet, eros orci gravida velit, non lobortis dolor erat quis orci. Suspendisse imperdiet laoreet tortor, at luctus nunc consequat ut. Fusce eu mi eros. Suspendisse sed arcu velit, ac commodo sem. Donec sit amet eros hendrerit lacus feugiat facilisis. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur sit amet suscipit mi. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus mollis, justo sit amet fringilla laoreet, eros orci gravida velit, non lobortis dolor erat quis orci. Suspendisse imperdiet laoreet tortor, at luctus nunc consequat ut. Fusce eu mi eros. Suspendisse sed arcu velit, ac commodo sem. Donec sit amet eros hendrerit lacus feugiat facilisis.</p> | |
| </div> |
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="double_left"> | |
| <img src="img/sample_project210_160.png" width="340" alt="Sample Project1"> | |
| <div class="image_meta">2008, HD video, 7 min 5s. Edition of 5.</div> | |
| </div> | |
| <div class="double_right"> | |
| <img src="img/sample_project210_160.png" width="340" alt="Sample Project1"> | |
| <div class="image_meta">2008, HD video, 7 min 5s. Edition of 5.</div> | |
| </div> |
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="triple_left"> | |
| <img src="img/sample_project210_160.png" width="220" alt="Sample Project1"> | |
| <div class="image_meta">2008, HD video, 7 min 5s. Edition of 5.</div> | |
| </div> | |
| <div class="triple_center"> | |
| <img src="img/sample_project210_160.png" width="220" alt="Sample Project1"> | |
| <div class="image_meta">2008, HD video, 7 min 5s. Edition of 5.</div> | |
| </div> | |
| <div class="triple_right"> | |
| <img src="img/sample_project210_160.png" width="220" alt="Sample Project1"> |
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="triple_left"> | |
| This is a section with text. To the right, is an empty section with no content and then a section with an image. In order to keep the structure in the empty section, it needs at least 1 piece of content: a "non-breaking space". See the code example below. | |
| </div> | |
| <div class="triple_center"> | |
| | |
| </div> | |
| <div class="triple_right"> | |
| <img src="img/sample_project210_160.png" width="220" alt="Sample Project1"> | |
| <div class="image_meta">2008, HD video, 7 min 5s. Edition of 5.</div> | |
| </div> |