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
| //*********** IMPORTS ***************** | |
| var gulp = require('gulp'); | |
| var sass = require('gulp-ruby-sass'); | |
| var gutil = require('gulp-util'); | |
| var rename = require("gulp-rename"); | |
| var map = require("map-stream"); | |
| var livereload = require("gulp-livereload"); | |
| var concat = require("gulp-concat"); | |
| var uglify = require('gulp-uglify'); | |
| var watch = require('gulp-watch'); |
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
| { | |
| "name": "MyProject", | |
| "version": "1.0.0", | |
| "dependencies": { | |
| "gulp": "*", | |
| "gulp-ruby-sass": "*", | |
| "gulp-util": "*", | |
| "gulp-rename": "*", | |
| "map-stream": "*", | |
| "gulp-livereload": "*", |
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
| /** | |
| * Get Age from BuddyPress date of Birth | |
| * @param string $dob_field_name :name of the DOB field in xprofile, like Dob or Date of Birth | |
| * @param int $user_id : the user for which you want to retrieve the age | |
| * @param string $format: the way you want to print the difference, look t <http://php.net/manual/en/dateinterval.format.php> for the acceptable agrs | |
| * @return string :the formatted age in year/month | |
| */ | |
| function bpdev_get_age_from_dob($dob_field_name,$user_id=false,$format="%y Years, %m Month(s), %d days"){ | |
| if(!$user_id) |
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
| /* | |
| Created by: Mauricio Rocha | |
| www.sampapix.com.br | |
| Install the plugins below, use -global or --save-dev either way will work. | |
| gulp, gulp-jade, gulp-concat, gulp-uglify, gulp-minify-css, gulp-stylus, gulp-obfuscate, gulp-connect | |
| Create the folders below inside your project folder: | |
| src, src/js, src/styl | |
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 | |
| // Colar no functions.php | |
| // Para remover os hooks | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_title' ); | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_price' ); | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt' ); | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_add_to_cart' ); | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_meta' ); | |
| remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_sharing' ); |
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 | |
| /** | |
| * WordPress Query Comprehensive Reference | |
| * Compiled by luetkemj - luetkemj.com | |
| * | |
| * CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
| * Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php | |
| */ | |
| $args = array( |
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
| /* Simulador */ | |
| #wc-correios-simulator { | |
| } | |
| /* Título do simulador */ | |
| #wc-correios-simulator strong { | |
| } |
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
| <ul class="products"> | |
| <?php | |
| $args = array( | |
| 'post_type' => 'product', | |
| 'posts_per_page' => 12 | |
| ); | |
| $loop = new WP_Query( $args ); | |
| if ( $loop->have_posts() ) { | |
| while ( $loop->have_posts() ) : $loop->the_post(); | |
| woocommerce_get_template_part( 'content', 'product' ); |
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
| // class dos links que vão receber o click | |
| $(".link-menu").on("click", function(event){ | |
| // a animação vai ocorrer no html, body | |
| $('html, body').animate({ | |
| // pega o atributo href do this (link que recebeu o click) | |
| // e faz a animação com velocidade 1000 para o destino do href; | |
| scrollTop: $($(this).attr("href")).offset().top |