Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-10-01 19:22:51

Mikkelrev
New Member
Registered: 2006-01-04
Posts: 7

Problem with acticle_custom

Well, I have some problems.
At my default page I’m showing an article from a section called “blogg” with this code
<txp:article_custom form="default" limit="1" section="blogg" />
And I’m also showing articles(thumbnails) from a section called foto
<txp:article_custom form="arkiv" limit="4" listform="arkiv" section="foto" />
And I got a page called fotoblogg where I’m showing the latest article from the same section as above.
<txp:article_custom limit=1 form="showfoto" section="foto" />

But It’s impossible to comment or view the posted comments. It just won’t display. But the URL shows that you are on the right article. For example
“http://xxxxxxx.com/blogg/17/test#comment”
But nothing happends.

And this is the code for the different forms. If it will help.

default:
<code>
<h1<txp:permlink>”<txp:title />”</txp:permlink></h1>
<txp:body />
<div id=“commentInfo”>
<p>Artikeln <em>”<txp:title />”</em> postades den <em>&lt;txp:posted /></em> i <em><txp:category1 /></em>. Du kanske också vill <txp:comments_invite /></p>
</div>
</div>
</code>
arkiv:
<txp:permlink><txp:bau_article_thumb /></txp:permlink>

showfoto:
<code>
<txp:link_to_prev><txp:article_image /></txp:link_to_prev>
<txp:body />
<div id=“commentInfo”>
<p>Denna bild postades den <em><txp:posted /></em>. Du kanske också vill <txp:comments_invite /></p>
</div>
</div>
</code>

I hope someone can help.

Thanks!

one more thing. I have a <ul><li> list and i dont know what code to use to show the last 5 posted articles.

Last edited by Mikkelrev (2006-10-01 19:47:18)

Offline

#2 2006-10-01 19:33:41

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

Re: Problem with acticle_custom

Posting code

You need to use <txp:article /> for individual articles. Also, if you’ve turned off auto-append comments in the Admin tab, you need to call the comments form from your article form using <txp:output_form form="comments_display" />.

Offline

#3 2006-10-01 19:46:53

Mikkelrev
New Member
Registered: 2006-01-04
Posts: 7

Re: Problem with acticle_custom

one more thing. I have a <ul><li> list and i dont know what code to use to show the last 5 posted articles.

And btw, thanks alot jm, now its working

Last edited by Mikkelrev (2006-10-01 19:50:19)

Offline

#4 2006-10-01 20:19:08

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

Re: Problem with acticle_custom

Section specific recent articles (requires auto-append to be off):

<code>
<ul>
<txp:article_custom form=“recent_articles_item” limit=“5” section=“yoursectionname” />
</ul>
</code>

form: recent_articles_item

<code>
<li><txp:permlink><txp:title /></txp:permlink></li> <!&#45;&#45;you can use article_image, etc in this form&#45;&#45;>
</code>

Or, to display the 5 most recent articles from any section, you can just use:

<code>
<txp:recent_articles break=“li” class=”“ wraptag=“ul” />
</code>

Offline

Board footer

Powered by FluxBB