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
| # Enable Image Expiry | |
| <IfModule mod_expires.c> | |
| ExpiresActive On | |
| # Images | |
| ExpiresByType image/jpeg "access plus 1 year" | |
| ExpiresByType image/gif "access plus 1 year" | |
| ExpiresByType image/png "access plus 1 year" | |
| ExpiresByType image/webp "access plus 1 year" | |
| ExpiresByType image/svg+xml "access plus 1 year" |
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 | |
| // Allow SVG | |
| add_filter( 'wp_check_filetype_and_ext', function($data, $file, $filename, $mimes) { | |
| global $wp_version; | |
| if ( $wp_version !== '4.7.1' ) { | |
| return $data; | |
| } | |
| $filetype = wp_check_filetype( $filename, $mimes ); | |
| return [ |
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 | |
| /* Popup */ | |
| function coupon_popup() { | |
| global $wpdb; | |
| $table_name = $wpdb->prefix . "gf_addon_feed"; | |
| $coupon = "gravityformscoupons"; | |
| $result = $wpdb->get_results( "SELECT * FROM $table_name WHERE addon_slug = '$coupon' " ); | |
| foreach($result as $couponData){ |
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 | |
| global $post; | |
| function blog_lists($atts) { | |
| $a = shortcode_atts(['take' => 10, 'category' => 'uncategorized', 'sorted' => 'no', 'posts_per_page' => 10], $atts ); | |
| ob_start(); | |
| $count = 0; | |
| $paged = (get_query_var('paged')) ? get_query_var('paged') : 1; | |
| $args = ['post_type' => 'post', 'posts_per_page' => 10,'paged' => $paged]; | |
| if ($a['category'] != 'all') { |
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 | |
| function getpluginVersion() { | |
| $update_plugins = get_site_transient( 'update_plugins' ); | |
| $required_plugins = $update_plugins->response; | |
| $current_plugins = $update_plugins->checked; | |
| if ( ! empty( $required_plugins ) ) : | |
| ?> | |
| <table> |
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
| function get_breadcrumb() { ?> | |
| <div class="container-fluid breadcrumb"> | |
| <div class="container"> | |
| <div class="row"> | |
| <div class="py-1"> | |
| <?php echo do_shortcode('[custom_breadcrumbs]'); ?> | |
| </div> | |
| </div> | |
| </div> | |
| </div> |
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
| function get_breadcrumb() { ?> | |
| <div class="container-fluid breadcrumb"> | |
| <div class="container"> | |
| <div class="row"> | |
| <div class="py-1"> | |
| <?php | |
| echo '<a href="'.home_url().'" rel="nofollow">Home</a>'; | |
| if (is_category() || is_single()) { | |
| echo " » "; | |
| the_category(' • '); |
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
| <script> | |
| // Put the data attribute value in the box. | |
| $(document).on('focus','.modal-toggle',function(){ | |
| $('.sp_title input').val($(this).data('package')); | |
| $('.sp_price input').val($(this).data('price')); | |
| $('.package_title').html($(this).data('package')); | |
| $('.package_price').html($(this).data('price')); | |
| }); | |
| </script> |
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 | |
| /* Popup Shortcode */ | |
| function popup_shortcode() { ?> | |
| <div class="mask" role="dialog"></div> | |
| <?php $args = array( | |
| 'post_type' => 'packages', | |
| 'post_status' => 'publish', | |
| 'posts_per_page' => -1, | |
| 'order' => 'ASC' |
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 | |
| /* Random Categories */ | |
| function category_shortcode() { | |
| ob_start(); | |
| $array = array( | |
| 'datasheet_category','infographic_category', | |
| ); | |
| $taxonomy = array_rand($array); | |
| $rand_taxonomy = $array[$taxonomy]; |