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
//vc_link ++ vc_param | |
array( | |
'type' => 'vc_link', | |
'heading' => __( 'Button', 'my-text-domain' ), | |
'param_name' => 'url', | |
), | |
//Shortcode | |
function vc_link_demo( $atts, $content = null) { | |
extract(shortcode_atts(array( | |
'url' => '' |
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
Use Latest wordpress & woocommerce with Perfect SEO URL Plugin 2.6.7 | |
The product-category not removed from 3.3.x woocommerce | |
Tricks here Credit - https://timersys.com/remove-product-category-slug-woocommerce/ | |
------------ | |
add_filter('request', function( $vars ) { | |
global $wpdb; | |
if( ! empty( $vars['pagename'] ) || ! empty( $vars['category_name'] ) || ! empty( $vars['name'] ) || ! empty( $vars['attachment'] ) ) { | |
$slug = ! empty( $vars['pagename'] ) ? $vars['pagename'] : ( ! empty( $vars['name'] ) ? $vars['name'] : ( !empty( $vars['category_name'] ) ? $vars['category_name'] : $vars['attachment'] ) ); | |
$exists = $wpdb->get_var( $wpdb->prepare( "SELECT t.term_id FROM $wpdb->terms t LEFT JOIN $wpdb->term_taxonomy tt ON tt.term_id = t.term_id WHERE tt.taxonomy = 'product_cat' AND t.slug = %s" ,array( $slug ))); |
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
// Ref: https://www.elementcycles.net/ | |
// Hide header on scroll down, show on scroll up | |
var did_scroll; | |
var last_scroll_top = 0; | |
var trigger_height = 5; | |
var navbar_height = $('.global-header').outerHeight(); | |
$(window).scroll(function() { | |
did_scroll = true; | |
}); |
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
// Custom Post Types | |
function wpt_job_post_type() { | |
$labels = array( | |
'name' => 'Vacancies', | |
'singular_name' => 'Job Opportunity', | |
'add_new' => 'Add New Job', | |
'add_new_item' => 'Add New Job Opportunity', | |
'edit_item' => 'Edit Job', |
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 | |
/** | |
* Example code for tutorial post on custom meta boxes: | |
* https://wptheming.com/2010/08/custom-metabox-for-post-type/ | |
*/ | |
/** | |
* Registers the event post type. | |
*/ | |
function wpt_event_post_type() { |
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
<div class="row"> | |
<div class="col-md-4"> | |
<div class="form-group"><label>Post Applied For</label> | |
[select* post class:form-control "Operator" "Jr. Exe" "Sr. Exe" "Deputy Manager" "GM" "VP" "ASM" "ZSM" "DRSM" "SPO" "BDO" "BDM"]</div> | |
</div> | |
<div class="col-md-4"> | |
<div class="form-group"><label>Experience Year</label> | |
[text* exp-year class:form-control ]</div> | |
</div> | |
<div class="col-md-4"> |
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 | |
/* | |
UPDATED: December 31, 2011. | |
Modifications: | |
- Truncated the longest country names, including: | |
-- British Indian Ocean Territories (Chagos Archipelago) -> British Indian Ocean Territories | |
-- South Georgia and the South Sandhich Islands -> South Georgia & S. Sandwich Islands |
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
<header> | |
<a href="#>WISH LIST COUNT : <span>0</span></a> | |
</header> | |
// Button only without ajax loading GIF | |
<a href="http://yoursite.com/product/product-2/?add_to_wishlist=218" rel="nofollow" data-product-id="218" data-product-type="simple" class="add_to_wishlist">Add to Wishlist</a> | |
// Default wishlist button mark up | |
<div class="yith-wcwl-add-to-wishlist add-to-wishlist-218"> |
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
File size limit Htaccess: | |
----------------------------------------- | |
php_value upload_max_filesize 64M | |
php_value post_max_size 64M | |
php_value max_execution_time 300 | |
php_value max_input_time 300 | |
Woocommerce Demo Content |
NewerOlder