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
// -- counter -- // | |
$(".counter_number span").counterUp({ | |
delay : 10, | |
time : 1000, | |
}); |
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
// -- modal video -- // | |
$(".play_icon").modalVideo(); | |
$(".play_icon").on('click', function(){ | |
return false; | |
}); |
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
wp comment must : | |
==================================== | |
/* | |
Theme Name: Philosophy | |
Theme URI: | |
AUTHOR: MD Tanjim Ahmmed | |
AUTHOR URI: https://tanjimahmmed.github.io/tanjim-portfolio/ | |
Description: Philosophy by colorlib | |
Version: 1.0 | |
License: GNU General Public License v2 or later |
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 | |
require_once(get_theme_file_path("/inc/tgm.php")); | |
require_once(get_theme_file_path("/inc/attachments.php")); | |
if (site_url()=="http://127.0.0.1/demo.tanjim.com"){ | |
define("VERSION", time()); | |
}else{ | |
define("VERSION",wp_get_theme()->get("version")); | |
} |
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 | |
$philosophy_fp = new WP_Query( | |
array( | |
'meta_key' => 'featured', | |
'meta_value'=> '1', | |
'posts_per_page'=> 3 | |
) | |
); | |
$post_data = 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
<?php | |
define('ATTACHMENTS_SETTINGS_SCREEN', false); | |
add_filter('attachments_default_instance', '__return_false'); | |
// field area | |
function philosophy_attachments($attachments){ | |
// if else | |
$post_id = null; | |
if( isset( $_REQUEST['post']) || isset( $_REQUEST['post_ID'] ) ){ | |
$post_id = empty($_REQUEST['post_ID']) ? $_REQUEST['post'] : $_REQUEST['post_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
function philosophy_cpt_slug_fix($post_link, $id){ | |
$p = get_post($id); | |
if(is_object($p) && 'chapter'==get_post_type($id)){ | |
$parent_post_id = get_field('parent_book'); | |
$parent_post = get_post($parent_post_id); | |
if($parent_post){ | |
$post_link = str_replace("%book%", $parent_post->post_name,$post_link); | |
} | |
} | |
return $post_link; |
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
add_action( 'init', 'my_theme_custom_post' ); | |
function my_theme_custom_post() { | |
register_post_type( 'cpt', | |
array( | |
'labels' => array( | |
'name' => __( 'CPTs' ), | |
'singular_name' => __( 'CPT' ) | |
), | |
'supports' => array('title', 'editor', 'custom-fields', 'thumbnail', 'page-attributes'), | |
'public' => true |
OlderNewer