Skip to content

Instantly share code, notes, and snippets.

View wowthemesnet's full-sized avatar

WowThemes.net wowthemesnet

View GitHub Profile
@wowthemesnet
wowthemesnet / gulpfile.js
Last active March 9, 2020 00:16
Gulp-zip for Gulp4
function deploy() {
return src([
'./**/*',
'!bower_components',
'!./{node_modules,node_modules/**/*}',
'!./package-lock.json',
'!./debug.log',
'!./gitignore',
'!./assets/{sass,sass/*}'
], {base: "."})
@wowthemesnet
wowthemesnet / functions.php
Created May 4, 2020 11:56
Getting download link from EDD store using URL variable
<?php
function add_query_vars_filter( $vars ){
$vars[] = "item";
return $vars;
}
add_filter( 'query_vars', 'add_query_vars_filter' );
get_query_var('item');
@wowthemesnet
wowthemesnet / functions.php
Created June 1, 2020 16:45
Get Media Embedded in Content WordPress
<?php $audio_media = get_media_embedded_in_content(
apply_filters( 'the_content', get_the_content() ), array( 'audio')
);
if ( has_post_format( 'audio' )) {
foreach ($audio_media as $audio_med) {
echo $audio_med;
}
}
?>
@wowthemesnet
wowthemesnet / terminal
Created October 26, 2020 19:30
steps to first publish repo
git init
git add .
git commit -m "first"
git remote add origin "xxxxxxxxxxx.git"
git push --set-upstream origin master