
Viewing 6 posts - 1 through 6 (of 6 total)
-
AuthorPosts
-
January 11, 2018 at 9:00 pm #896240
Hi
I’am using the code underneath for a custom page that works fine however I would like to change the widget in the right column (recent posting) into a existing widget. Can you tell me how to do this?<?php if ( !defined('ABSPATH') ){ die(); } global $avia_config; /* * get_header is a basic wordpress function, used to retrieve the header.php file in your theme directory. */ get_header(); $title = __('Blog - Latest News', 'avia_framework'); //default blog title $t_link = home_url('/'); $t_sub = ""; if(avia_get_option('frontpage') && $new = avia_get_option('blogpage')) { $title = 'Staff'; //if the blog is attached to a page use this title $t_link = get_permalink($new); $t_sub = avia_post_meta($new, 'subtitle'); } if( get_post_meta(get_the_ID(), 'header', true) != 'no') echo avia_title(array('heading'=>'strong', 'title' => $title, 'link' => $t_link, 'subtitle' => $t_sub)); do_action( 'ava_after_main_title' ); ?> <div class='container_wrap container_wrap_first main_color <?php avia_layout_class( 'main' ); ?>'> <div class='container template-blog template-single-blog '> <main class='content units <?php avia_layout_class( 'content' ); ?> <?php echo avia_blog_class_string(); ?>' <?php avia_markup_helper(array('context' => 'content','post_type'=>'post'));?>> <?php /** * Single Staff Member * */ // First we get fields from our staff member custom post type into variables global $post; $custom = get_post_custom(); $t_name = get_the_title(); $name_slug = basename(get_permalink()); $title = $custom["_staff_member_title"][0]; $email = $custom["_staff_member_email"][0]; $phone = $custom["_staff_member_phone"][0]; $fax = $custom["_staff_member_fax"][0]; $bio = $custom["_staff_member_bio"][0]; $prof = $custom["_staff_member_prof"][0]; $fb_url = $custom["_staff_member_fb"][0]; if(has_post_thumbnail()){ $t_photo_url = wp_get_attachment_url( get_post_thumbnail_id() ); $t_photo = '<img class="staff-member-page-photo" src="'.$t_photo_url.'" alt = "'.$title.'">'; }else{ $t_photo_url = ''; $t_photo = ''; } $email_mailto = '<a class="staff-member-email" href="mailto:'.antispambot( $email ).'" title="Email '.$name.'">'.antispambot( $email ).'</a>'; ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <header class="entry-header"> <?php /* The loop */ ?> <?php while ( have_posts() ) : the_post(); ?> <div class="staff-member-wal"> <h2><?php the_title(); ?></h2> <!-- This is the Standard page title --> <h3><?=$title?></h3> <!-- This is the Staff Memeber Title --> <?=$t_photo?> <!-- This is the Staff Memeber Photo --> <?php if ($bio){ echo '<div>' . wpautop( $bio ) . '</div>'; } ?> <?php the_content();?> <?php endwhile; ?> </div> <!--end content--> </main> <?php $avia_config['currently_viewing'] = "blog"; //get the sidebar get_sidebar(); ?> </div><!--end container--> </div><!-- close default .container_wrap element --> <?php get_footer(); ?>
January 12, 2018 at 12:56 am #896347Hey NWSchool,
Can you explain a little more clearer as to what you are trying to achieve?
Best regards,
Jordan ShannonJanuary 12, 2018 at 1:02 am #896354i got a widget with staff member groups and I would like to use that in the column on the custom page.
January 13, 2018 at 12:36 am #896747do you need more info?
January 14, 2018 at 12:45 am #896983bumb
January 14, 2018 at 11:10 pm #897239Hi,
Please go to Appearance -> Widgets and from there check the Blog Sidebar
Best regards,
Basilis -
AuthorPosts
Viewing 6 posts - 1 through 6 (of 6 total)
- You must be logged in to reply to this topic.