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 | |
/** Start Auto-Create Terms in Secondary Taxonomy */ | |
add_action( 'created_term', 'custom_create_taxonomy_term', 10, 3 ); | |
function custom_create_taxonomy_term( $term_id, $tt_id, $taxonomy ) { | |
/** Define mapping between source taxonomies and destination taxonomies */ | |
$taxonomy_mapping = array( | |
'product_cat' => 'your_target_taxonomy', | |
'category' => 'your_target_taxonomy', | |
); |
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
.bnav_bottom_nav_wrapper { | |
display: block !important; | |
margin-left: auto; | |
margin-right: auto; | |
display: block; | |
width: 420px; | |
::-webkit-scrollbar { | |
height: 4px; | |
width: 4px; |
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 | |
//stap one ajax action fire on a plugin | |
public function __construct() { | |
$this->register_ajax_hooks(); | |
} |
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 | |
//Walker function | |
function custom_taxonomy_walker($taxonomy, $parent = 0) | |
{ | |
$terms = get_terms($taxonomy, array('parent' => $parent, 'hide_empty' => false)); | |
//If there are terms, start displaying | |
if(count($terms) > 0) | |
{ | |
//Displaying as a list | |
$out = "<ul>"; |
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 | |
function wpdocs_deregister_section( $wp_customize ) { | |
$main_section_id = 'custom_marker_icon'; | |
$wp_customize->add_section( $main_section_id , [ | |
'title' => __( 'Custom Marker Icon', 'timeandtidebell-vgm-add-on' ), | |
'description' => __( 'Upload Marker Icon', 'timeandtidebell-vgm-add-on' ), | |
] ); |
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
global $wp_session; | |
$wp_session['set_session_name'] = set_the_value; | |
$data = ''; | |
if(isset($_COOKIE['set_session_name'])){ | |
$data = $_COOKIE['set_session_name']; | |
} | |
//input field | |
value="<?php echo $data; ?>" |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>date time</title> | |
</head> |
NewerOlder