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
sudo chown -R bitnami:daemon public | |
sudo find public -type d -exec chmod 775 {} \; | |
sudo find public -type f -exec chmod 664 {} \; | |
sudo chmod 640 public/wp-config.php |
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
cp -a /source/. /dest/ |
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
return axios('https://v.shopify.com/slate/track', axiosConfig).catch(() => {}); |
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
/** | |
* When developing locally define these constants in your wp-config.php instead to your database. | |
* This saves time when moving your database. | |
*/ | |
if (!defined('WP_SITEURL')) { | |
define('WP_SITEURL', 'http://' . $_SERVER['SERVER_NAME']); | |
} | |
if (!defined('WP_HOME')) { | |
define('WP_HOME', 'http://' . $_SERVER['SERVER_NAME']); |
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
<script type="text/javascript"> | |
$(document).ready(function(){ | |
$('a[href^="#"]').on('click',function (e) { | |
e.preventDefault(); | |
var target = this.hash; | |
var $target = $(target); | |
$('html, body').stop().animate({ | |
'scrollTop': $target.offset().top | |
}, 900, 'swing', function () { | |
window.location.hash = target; |
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
ln -s `which php72` ~/bin/php | |
export PATH=$HOME/bin:$PATH | |
cd bin | |
curl -sS https://getcomposer.org/installer | php72 | |
echo -e "\n# Composer\nalias composer=\"php72 \$HOME/bin/composer.phar\"" >> $HOME/.bash_profile | |
source $HOME/.bash_profile |
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 | |
//Paste the code below into the widget logic field of you widget and edit the page IDs as needed | |
//The code below will display your widget on pages 8,9 and 10 and any page that is a child of page 8 | |
global $post; return (is_page(array(8,9,10)) || in_array($post->post_parent, array(8))); | |
//The code below will display you widget on pages that us the faq-page.php template file | |
global $post; return (get_page_template_slug( $post->ID ) == 'page-templates/faq-page.php'); |
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
jQuery(document).ready(function(){ | |
//set up the vars | |
var eCat = 'contact', | |
eAct = '', | |
eLabel = window.location.pathname; | |
//target href attributes that begin tel: | |
jQuery(document).on('click','[href^="tel:"]', function(e) { | |
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
vagrant ssh | |
sudo su | |
nano /etc/php/7.0/apache2/php.ini | |
#use the sort cut to find the setting 'memory_limit' and update | |
[ctrl]+[w]memory_li | |
memory_limit 1024M | |
#use the sort cut to find the setting 'post_max_size' and update | |
[ctrl]+[w]post_max |
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
# ssh to your vagrant server (scotchbox) | |
vagrant ssh | |
# swich to super user account (administrator / root) | |
sudo su | |
# update apt-get | |
apt-get update | |
# install the latest version of xml support for php7 | |
apt-get install php7.0-xml | |
# install the latest version of xml support for php7 |