WordPress.org

Ready to get started?Download WordPress

Forums

Co-Authors Plus
Artisteer and Co-Authors plus (2 posts)

  1. thelostswede
    Member
    Posted 1 year ago #

    I can't figure out how to use this with an Artisteer generated template, in as much as I have no idea how to edit the generated code to make it display multiple authors. The closest I got was to get rid of the authors altogether. The site is - http://cravings.tw

    This appears to be the correct code to edit, but nothing I change seems to have any effect

    if (!function_exists('get_the_author_meta')) {
    	function get_the_author_meta($field = '', $user_id = false) {
    		if (!user_id) {
    			global $authordata;
    		} else {
    			$authordata = get_userdata($user_id);
    		}
    
    		$field = strtolower($field);
    		$user_field = 'user_' . $field;
    
    		if ( 'id' == $field ) {
    			$value = isset($authordata->ID) ? (int) $authordata->ID : 0;
    		} elseif (isset($authordata->$user_field)) {
    			$value = $authordata->$user_field;
    		} else {
    			$value = isset($authordata->$field) ? $authordate->$field : '';
    		}
    
    		return apply_filters('get_the_author_' . $field, $value, $user_id);

    Cheers

    http://wordpress.org/extend/plugins/co-authors-plus/

  2. Daniel Bachhuber
    Hand Built
    Plugin Author

    Posted 1 year ago #

    I don't think is the code you want to be changing...

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.