Skip to content

Instantly share code, notes, and snippets.

View jbalzar's full-sized avatar

Jessie Baltazar jbalzar

  • 15:35 (UTC +08:00)
View GitHub Profile
@jbalzar
jbalzar / genesis_remove_post.php
Last active March 19, 2016 11:45
Remove post in Genesis homepage
<?php
add_action ( 'get_header' , 'home_remove_post' );
function home_remove_post() {
if( is_home() || is_front_page() ) {
remove_action( 'genesis_loop', 'genesis_do_loop' );
add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' );
}
}
@jbalzar
jbalzar / genesis_custom_widget_area.php
Last active March 19, 2016 11:46
Custom widget area in Genesis
<?php
add_action( 'genesis_after_header', 'custom_widget_name' );
function custom_widget_name() {
genesis_widget_area ('custom_widget_name', array(
'before' => '<div class="custom_widget_name"><div class="wrap">',
'after' => '</div></div>',
) );
}
@jbalzar
jbalzar / mcrypt
Created September 4, 2015 18:11
Install mcrypt module ubuntu
sudo apt-get install mcrypt php5-mcrypt
sudo php5enmod mcrypt
sudo service apache2 restart
@jbalzar
jbalzar / composer.bash
Last active April 23, 2016 05:51
Install composer on ubuntu
curl -sS https://getcomposer.org/installer | php
mv composer.phar /usr/local/bin/composer
@jbalzar
jbalzar / mailcatcher.bash
Last active April 23, 2016 05:52
Enable Mailcatcher on Linux
# http://mailcatcher.me/
gem install mailcatcher
# $ mailcatcher --help
# Usage: mailcatcher [options]
# --ip IP Set the ip address of both servers
# --smtp-ip IP Set the ip address of the smtp server
# --smtp-port PORT Set the port of the smtp server
# --http-ip IP Set the ip address of the http server
@jbalzar
jbalzar / node-for-root-user
Last active April 23, 2016 05:52
NodeJS fix for "/usr/bin/env: node: No such file or directory"
"ln -s /usr/bin/nodejs /usr/bin/node"
@jbalzar
jbalzar / gulp.js
Created August 24, 2015 08:33
BrowserSync for Laravel Elixir
/**
* gulp.js file
*
* Github Repo
* https://github.com/ponko2/laravel-elixir-browser-sync
*
* Node Install
*
* Laravel Elixir 2.x
* npm install [email protected] --save-dev