Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2009-06-23 16:56:03

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

How do I create author "pages"

Hello, I am setting up a blog that will have multiple (about 10) contributors. My initial thinking is that I will set up a section for each contributor, so that I can display a brief bio of each one in the right column, and then use the sort by author function on the article form to display that author’s posts on that page.

My question, though, is there a way to have the bios, as well as the articles, appear without having to define a section for each author? Is there some way I can set up one “authors” section, one page layout, and have each author’s page dynamically displayed via TXP? I have been researching article_custom and I can’t quite get my mind around the answer here.

Thanks, and let me know if you need more explanation of my goals.

Offline

#2 2009-06-23 21:30:02

jm
Plugin Author
From: Missoula, MT
Registered: 2005-11-27
Posts: 1,746
Website

Re: How do I create author "pages"

Offline

#3 2009-06-24 02:12:18

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

Re: How do I create author "pages"

That looks interesting. Thank you! Any ideas how I could streamline the site construction by not having to make a section for each author?

Thanks.

Offline

#4 2009-06-24 02:43:08

MattD
Plugin Author
From: Monterey, California
Registered: 2008-03-21
Posts: 1,254
Website

Re: How do I create author "pages"

Why do you need a section for each author? What are you trying to do?

You could link to articles by the author like http://site.com/author/first_name+last_name.


My Plugins

Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker

Offline

#5 2009-06-24 03:08:46

jm
Plugin Author
From: Missoula, MT
Registered: 2005-11-27
Posts: 1,746
Website

Re: How do I create author "pages"

gooberboy wrote:

Any ideas how I could streamline the site construction by not having to make a section for each author?

In the tutorial, you only create one section as a container for authors (“staff”) and post the bios as articles to that section.

Offline

#6 2009-06-24 04:33:47

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

Re: How do I create author "pages"

Okay, I’m getting there, but the tutorial explains how to link to a profile, not display it directly on an author’s page. Any ideas there? Thanks!

Offline

#7 2009-06-24 04:36:35

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

Re: How do I create author "pages"

And yes, I figured out how to create links to combined section and author pages. Now I just need to figure out how to display the bios on the pages generated by those links, such as the one you described: http://site.com/author/first_name+last_name.

Offline

#8 2009-06-24 05:12:49

MattD
Plugin Author
From: Monterey, California
Registered: 2008-03-21
Posts: 1,254
Website

Re: How do I create author "pages"

you want a page with the author article and a list of articles by that author? You could use txp:if_author to determine if your on an author page then use one txp:article_custom tag to display the author article then a txp:article_custom to display the articles for that author.


My Plugins

Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker

Offline

#9 2009-06-24 05:21:30

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

Re: How do I create author "pages"

Yes, my goal is to have a page with the author’s articles displayed (I’ve figured that part out), as well as a sidebar section with a bio for that author on the same page. What variable(s) should I use to display the bio with txp:article_custom? I have an article that is titled with the name of the author, but not sure where to go from there…

Offline

#10 2009-06-24 05:36:20

MattD
Plugin Author
From: Monterey, California
Registered: 2008-03-21
Posts: 1,254
Website

Re: How do I create author "pages"

Would this work?

<txp:if_author name="joe">
<txp:article_custom id="55" />
</txp:if_author>
<txp:if_author name="jane">
<txp:article_custom id="56" />
</txp:if_author>

My Plugins

Piwik Dashboard, Google Analytics Dashboard, Minibar, Article Image Colorpicker, Admin Datepicker, Admin Google Map, Admin Colorpicker

Offline

#11 2009-06-24 07:43:14

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: How do I create author "pages"

Or if you have bio article for every author, every one in a same section called biostorage.

<txp:article_custom section="biostorage" author='<txp:author />' limit="1">
	<h2>Bio of <txp:author /></h2>
	<txp:body />
</txp:article_custom>

Which you could use in compination with (for example within) the context sensitive <txp:article />.

Offline

#12 2009-06-24 15:53:54

gooberboy
Member
From: Seattle
Registered: 2008-02-15
Posts: 25
Website

Re: How do I create author "pages"

Jukka, I am trying your method first. On a page with this URL:

http://www.embrocationmagazine.com/dev/index.php?s=online&author=Joshua+Gunn

I have:

<txp:article>
<txp:output_form form="rss_author_info"/>
<txp:article_custom section="author" author='<txp:author />' limit="1">
<h2>ABOUT <txp:author /></h2>
<txp:rss_author_info_image  /><txp:body />
</txp:article_custom>
</txp:article>

Nothing displays when I use this. Am I doing something wrong? I have the bio in the right section (author).

Note that I have included the author_info plugin, but I don’t think that makes a difference.

Do I need to make an article form to get this to work?

Thanks.

Offline

Board footer

Powered by FluxBB