</div> <div class="clear"></div> <p><a href="#" class="js_inpost_gallery_add_slide button button-primary"><?php _e('Add images', 'almera'); ?> </a></p> <script type="text/javascript"> jQuery(function() { jQuery("#gallery_img_categoriesdiv").remove(); }); </script> <ul id="gallery_item_list"> <?php if (!empty($tmm_gallery)) { ?> <?php foreach ($tmm_gallery as $value) { ?> <?php TMM_Gallery::render_gallery_item($value); ?> <?php } ?> <?php } ?> </ul> <div class="clear"></div> </div>
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 } } } }