Hi,
I'd like to create a node that displays a chronological list of all posts by a user regardless of the node type and that returns it's own search results.

I'm thinking of fairly simple search results. I'd like site visitors to be able to type in part of a user's name and get a list of possible matches. While this is currently possible, I want the link to point to the chronological list of all posts and not to the user profile page.

I'm just starting to think this through, but it seems that i'll need to use the _update_index() hook. Unfortunately, I couldn't find any documentation on it.

Looking at the node module, it seems that I need to send an array with the Last_update, node_type and select (the sql query). But where do I define what the title and url should be of the result links?

Thanks in advance,
- Joe

Comments

moshe weitzman’s picture

i'm unsure still of what you are trying to achieve. start with the custom node. what are the fields for this custom node? are there many text fields?

format of search results can't currently be customized for a given node type. that applies to the link on a username.

joe lombardo’s picture

The node would only serve the purpose of providing a view to all of a users posts, vs all of the user's blog entries and providing a search results page that linked to that view. So there weren't going to be any fields at all.

The end goal is a search box that finds a user and links to a chronological listing of all their posts including recipes, journal entries, polls any node type.

An out of the box site is very node centric. I want to shift the center a little closer to the author, at least cosmetically.


Joe Lombardo | joe@familytimes.com | My Blog
moshe weitzman’s picture

the format of search results can be customized by node modules by implementing the _search_item() hook. see search_item() in includes/common.inc

moshe weitzman’s picture

you don't need a new node type for that. in fact, most of your work is done already. tracker.module already supports viewing all posts by a given user. the syntax is tracker/{uid}. for example, scan all posts by Joe or Moshe.

There used to be a link to this page on everyone's user profile page but Dries removed it because he thought noone used it. I agree that viewing all posts for a given user is invaluable once you find an author whose posts you enjoy reading. If you agree, please petition Dries to bring it back.

In the meanwhile, you can add back the link on the user profile page by creating a small module which implements the _user() hook. if you want all usernames to point to this link instead of the user profile page, that is a simple tweak to format_name() in includes/common.inc

ax’s picture

as subject. really missing that.

moshe weitzman’s picture

i notice now that the link is displayed when you view other people's user page but not your own. that seems strange to me. i'm submitting a patch which fixes this.

joe lombardo’s picture

Fantastic! Thanks very much for your help :-)

Dries, if you are reading this, please consider it a petition to bring back the link to a user's collection of entries. ;-) I believe many author's are motivated to create a relationship with their readers, and vice-versa. It seems to follow that by enabling a reader to see a collection of posts by a single author we can facilitate that relationship building. This kind of functionality is all the more important on a site with many authors.

Cheers,
- Joe


Joe Lombardo | joe@familytimes.com | My Blog
al’s picture

How about we implement friend lists (like Slashdot does)? So you can find blog entries up to x levels of friends deep.

joe lombardo’s picture

Good idea!

What do you think about a recently viewed blog list? A box that would list the blogs that you (the user) most recently viewed? I guess this is a little like a friends list, though determined by user actions instead of user definitions.

- Joe