I've used the PHP snippet found here which creates "Custom user profile page with (x) latest weblog entries of that user". the output is just what we want, except each teaser also displays the $submitted information such as the username, extra profile fields that we've added, as well as the user pic.

Since this is the user profile page and their picture is already displayed at the top, this is redundant when displaying their picture next to each teaser. We'd like to get rid of the picture displayed next to each teaser, as well as remove the $submitted information OTHER than the date it was submitted.

The query we're using to get the (x) latest weblog entries for that user:
Within template.tpl.php:

function phptemplate_user_profile($user, $fields = array()) {
  // Pass to phptemplate, including translating the parameters to an associative array. The element names are the names that the variables
  // will be assigned within your template.
  /* potential need for other code to extract field info */
  return _phptemplate_callback('user_profile', array('user' => $user, 'fields' => $fields));
}

and this is the code we're using within user_profile.tpl.php:

<div class="fields"><b>Latest Blog Entries: </b><br><br>
<?php
unset($output);
/**
* This php snippet displays the 10 most recent weblog entries by a specific user with
* teaser & info.
*/

  $listlength=20;
  $userid=$user->uid;
  $result1 = pager_query(db_rewrite_sql("SELECT n.nid, n.created FROM {node} n WHERE n.type = 'aggregator2-item' AND n.status = 1 AND n.uid = $userid ORDER BY n.created DESC"), variable_get('default_nodes_main', $listlength));
  while ($node = db_fetch_object($result1)) {
    $output .= node_view(node_load(array('nid' => $node->nid)), 1);
  }
print $output;
?> 

Any suggestions are greatly appreciated,
Thanks,
-=Vince

Technology White Papers