Keeping permissions and hidden files inside the root folder
Run this from the command line inside the main folder you want to zip:
shopt -s dotglob && tar -czvpf websitename.tar.gz . && shopt -u dotglob
<?php | |
/** | |
* The template for displaying cpt with isotope, bootstrap 4 and acf | |
* Template Name: Custom Isotope | |
* | |
* @package wordpress | |
*/ | |
get_header(); | |
?> |
<?php | |
/** | |
* Change shipping message in cart and checkout | |
*/ | |
add_filter( 'woocommerce_no_shipping_available_html', 'littleargentina_no_shipping_message' ); | |
add_filter( 'woocommerce_cart_no_shipping_available_html', 'littleargentina_no_shipping_message' ); | |
function littleargentina_no_shipping_message( $message ) { | |
return __( 'We only ship to the UK. Please select "Deliver to a different address" if you are purchasing from outside the UK' ); | |
} | |
?> |
Here's a neat trick in Sublime Text 2 or 3 to convert your indentation spacing in a document.
TL;DR:
Converting from 2 spaces to 4 spaces:
Ensure tab width is set to 2. Convert your 2-space indentation to tabs, switch to tab width 4, and then convert the indentation back to spaces.
The detailed description:
"use strict"; | |
"object" != typeof window.CP && (window.CP = {}), window.CP.PenTimer = { | |
programNoLongerBeingMonitored: !1, | |
timeOfFirstCallToShouldStopLoop: 0, | |
_loopExits: {}, | |
_loopTimers: {}, | |
START_MONITORING_AFTER: 2e3, | |
STOP_ALL_MONITORING_TIMEOUT: 5e3, | |
MAX_TIME_IN_LOOP_WO_EXIT: 2200, | |
exitedLoop: function(o) { |
"use strict";"object"!=typeof window.CP&&(window.CP={}),window.CP.PenTimer={programNoLongerBeingMonitored:!1,timeOfFirstCallToShouldStopLoop:0,_loopExits:{},_loopTimers:{},START_MONITORING_AFTER:2e3,STOP_ALL_MONITORING_TIMEOUT:5e3,MAX_TIME_IN_LOOP_WO_EXIT:2200,exitedLoop:function(o){this._loopExits[o]=!0},shouldStopLoop:function(o){if(this.programKilledSoStopMonitoring)return!0;if(this.programNoLongerBeingMonitored)return!1;if(this._loopExits[o])return!1;var t=this._getTime();if(0===this.timeOfFirstCallToShouldStopLoop)return this.timeOfFirstCallToShouldStopLoop=t,!1;var i=t-this.timeOfFirstCallToShouldStopLoop;if(i<this.START_MONITORING_AFTER)return!1;if(i>this.STOP_ALL_MONITORING_TIMEOUT)return this.programNoLongerBeingMonitored=!0,!1;try{this._checkOnInfiniteLoop(o,t)}catch(o){return this._sendErrorMessageToEditor(),this.programKilledSoStopMonitoring=!0,!0}return!1},_sendErrorMessageToEditor:function(){try{if(this._shouldPostMessage()){var o={action:"infinite-loop",line:this._findAroundLineNumber()};parent |
/* WOW animations */ | |
.animated { | |
-webkit-animation-duration: 1s; | |
animation-duration: 1s; | |
-webkit-animation-fill-mode: both; | |
animation-fill-mode: both; | |
} | |
.animated.hinge { |
<?php | |
/** | |
* Add custom logo to login | |
*/ | |
function custom_login_logo() { ?> | |
<style type="text/css"> | |
#login h1 a, .login h1 a { | |
background-image: url(<?php echo get_stylesheet_directory_uri(); ?>/images/login-logo.png); | |
height:65px; | |
width:320px; |
<section class="content-section"> | |
<div class="container"> | |
<div class="row justify-content-center py-3"> | |
<div class="col-12 col-md-6 mb-3 pb-3"> | |
<?php the_field('left_column_content'); ?> | |
<div class="accordion" id="fact-accordion"> | |
<?php if( have_rows('accordion') ): ?> |
jQuery(function($){ | |
// Ekko lightbox attribute data-toggle to gallery links | |
$('.gallery-item').find('a').attr('data-toggle', 'lightbox'); | |
$('.gallery-item').find('a').attr('data-gallery', 'gallery'); | |
$('.gallery-item').find('a').attr('data-type', 'image'); | |
// enable ekko lightbox on page | |
$(document).on('click', '[data-toggle="lightbox"]', function(event) { | |
event.preventDefault(); | |
$(this).ekkoLightbox({ |