Example #1
0
if (!defined('ABSPATH')) {
    die('No direct access allowed');
}
$staff = explode('^', $staff);
$i = 1;
?>

<section class="row accHorizontal">

	<?php 
foreach ($staff as $post_id) {
    if (function_exists('icl_object_id')) {
        $post_id = icl_object_id($post_id, TMM_Staff::$slug, true, ICL_LANGUAGE_CODE);
    }
    $custom = TMM_Staff::get_meta_data($post_id);
    ?>

		<aside class="accHorizontal__item <?php 
    if ($animation) {
        echo $animation;
    }
    ?>
">
			<input type="checkbox" class="state" id="acc-<?php 
    echo $i;
    ?>
" />
			<label class="backdrop" for="acc-<?php 
    echo $i;
    ?>
function tmm_save_details()
{
    if (is_admin()) {
        if (!empty($_POST)) {
            if (isset($_POST['tmm_meta_saving'])) {
                global $post;
                $post_type = get_post_type($post->ID);
                switch ($post_type) {
                    case 'page':
                    case 'post':
                    case TMM_Portfolio::$slug:
                    case TMM_Gallery::$slug:
                    case TMM_Staff::$slug:
                        TMM_Gallery::save($post->ID);
                        TMM_Staff::save($post->ID);
                        TMM_Portfolio::save($post->ID);
                        break;
                    case 'testimonials':
                        TMM_Testimonials::save($post->ID);
                        break;
                    default:
                        break;
                }
                TMM_Page::save($post->ID);
                //for all types
            }
        }
    }
}