Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-05-22 11:43:25

Vincent2
New Member
Registered: 2010-05-08
Posts: 4

Edit post with javascript

Hi,

I’m trying this thing that uses javascript to show the posts, but I’m stuck somewhere.

I know this tag generates my posts (<txp:article limit=“5” />). Now is there a way of putting every single post in a class?

I’ve tried the following:

<div class=“post”>
<txp:article limit=“5” />
</div>

but this obviously only generates one div around all posts, what I want is a div around every 5 posts.

Can someone help me with this?

Offline

#2 2010-05-22 11:54:02

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,706
Website

Re: Edit post with javascript

The presentation of each individual article is determined by the form you are using. If you don’t specify form="my-form-name" as an attribute of txp:article it uses the form called default.

Add your opening and closing div to the form to put a div around each article.


TXP Builders – finely-crafted code, design and txp

Offline

#3 2010-05-22 13:04:45

Vincent2
New Member
Registered: 2010-05-08
Posts: 4

Re: Edit post with javascript

ow in forms you can adjust single post, thanks very much man!

Offline

Board footer

Powered by FluxBB