Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-09-05 19:59:14

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Correct article list

Hello. Yes, this is a shameful newbie question, but sometimes I walk around the FAQs and I don’t know exactly how to look for what I’m looking for (I mean, the name that this has).

Page: www.cinefriki.com
Problematic section: www.cinefriki.com/criticasfriki

The problem is (I know it sound stupid, but I really don’t know how to do it)

I have an article list:

<p><img src="http://cinefriki.com/img/cinefriki.jpg"></p> <txp:article_custom form="titles" listform="excerpt" limit="50" section="criticasfriki" sortby="Title" sortdir="desc" excerpted="n" author="malize" />

That displays the titles correcty. The question is, how should I write that, when you click the link, it has to display the article? What am I missing?

Thank you very much for your pacience with newbies like me.

Offline

#2 2007-09-05 20:25:34

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

Re: Correct article list

change <txp:article_custom /> to <txp:article />. <txp:article_custom />-tag isn’t content sensitive, and it doesn’t output single articles automatically.

<p><img src="http://cinefriki.com/img/cinefriki.jpg"></p>
<txp:article form="titles" listform="excerpt" limit="50" sortby="Title" sortdir="desc" excerpted="n" author="malize" />

Cheers!

Offline

#3 2007-09-05 22:20:08

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: Correct article list

Malize wrote:

<p><img src="http://cinefriki.com/img/cinefriki.jpg"></p> <txp:article_custom form="titles" listform="excerpt" limit="50" section="criticasfriki" sortby="Title" sortdir="desc" excerpted="n" author="malize" />

That displays the titles correcty. The question is, how should I write that, when you click the link, it has to display the article? What am I missing?

Look at your form ‘titles’. To make the titles link to the articles, it should look like

<txp:permlink><txp:title /></txp:permlink>

You can use <txp:article_custom /> but unlike <txp:article /> it can’t have the attribute ‘listform’.
Also change sortby="Title" sortdir="desc" into sort="Title desc".

(txp:article, txp:article_custom)

Offline

#4 2007-09-06 07:13:07

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Re: Correct article list

Thank you, thank you, thank you very much :)

Offline

#5 2007-09-06 07:20:06

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Re: Correct article list

I’ve made the changes you said, but the link, instead of going to de article, displays only the title of the article.

Offline

#6 2007-09-06 07:23:27

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,235
Website GitHub Mastodon Twitter

Re: Correct article list

What do you have in your default form?


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#7 2007-09-06 13:05:13

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Re: Correct article list

In the default form I have

<br> <h3><txp:permlink><txp:title /></txp:permlink></h3> <txp:body /> <br><br> <div align="center"><img src="<txp:site_url />images/1.gif" style="height:10px;width:410px" class="divider" alt="" /></div>

In the page template I have:
<txp:article form="titles" listform="excerpt" limit="100" section="criticasfriki" sort="Title desc" excerpted="n" author="malize" />

and the form “titles” is:

<h4><txp:permlink><txp:title /></txp:permlink> </h4>

Offline

#8 2007-09-06 14:48:17

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

Re: Correct article list

To output the list, ie:

<txp:if_article_list>
<txp:article form="titles" limit="50" sortby="Title" sortdir="desc" author="malize" />
<txp:else />
<txp:article />
</txp:if_article_list>

Cheers!

Last edited by Gocom (2007-09-06 14:49:35)

Offline

#9 2007-09-06 15:46:52

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Re: Correct article list

No, it doesn’t work, as you can see i http://cinefriki.com/criticasfriki :’(

Last edited by Malize (2007-09-06 15:47:17)

Offline

#10 2007-09-06 16:28:17

guiguibonbon
Member
Registered: 2006-02-20
Posts: 296

Re: Correct article list

Could you set the Production Status to debugging in the preferences tab?

You also have a huge number of queries for such a simple page. I wonder what’s going on there.

Offline

#11 2007-09-06 16:34:30

guiguibonbon
Member
Registered: 2006-02-20
Posts: 296

Re: Correct article list

Malize, in fact, it seems to work, except the content of your articles seem to land in the left column somehow.

Still, all those error messages are very strange.

Offline

#12 2007-09-06 20:06:49

Malize
Member
From: Barcelona
Registered: 2007-08-28
Posts: 77
Website

Re: Correct article list

/me cries…

WTF is this O_O

tag_error <txp:article form=“title” limit=“100” sortby=“Title” sortdir=“desc” author=“malize” /> -> Textpattern Notice: form_not_found: title on line 1360

textpattern/lib/txplib_misc.php:1360 trigger_error()
textpattern/lib/txplib_misc.php:1376 fetch_form()
textpattern/publish.php:704 parse_form()
textpattern/publish.php:808 doArticles()
textpattern/publish.php:509 parseArticles()
textpattern/publish.php:963 article()
processTags()
textpattern/publish.php:922 preg_replace_callback()
textpattern/publish/taghandlers.php:2315 parse()
textpattern/publish.php:963 if_article_list()

I’ve never seen this, an I havn’t made any change since last time I visited the page… And the code on page template is not ·form:“title”· (as says the warning) but ·form=“titles”· that actually exists

buaaaaaa!! snif! snif!

Offline

Board footer

Powered by FluxBB