Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#13 2010-09-16 22:11:02
- els
- Moderator
- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: General help
Use two article tags. In the first one use limit="1"
, and for the second limit="1" offset="1"
.
Offline
#14 2010-09-16 22:40:19
- helmz
- Member
- Registered: 2010-09-14
- Posts: 65
Re: General help
Perfect! but it shows same article, is id=”“ what i need?
Offline
#15 2010-09-16 22:46:58
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,315
Re: General help
You must have chosen mine. Take Els’, it will display 2 different ones.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#16 2010-09-16 22:48:46
- helmz
- Member
- Registered: 2010-09-14
- Posts: 65
Re: General help
This is the code im using:
<div class="text">
<txp:article limit="1" >
<h1 class=“entry-title”><txp:title /></h1>
<p class=“published”></p>
<div class=“entry-content”>
<txp:body />
</div>
</txp:article>
<div class="text2">
<txp:article limit="1" offset="0" >
<h1 class=“entry-title”><txp:title /></h1>
<p class=“published”></p>
<div class=“entry-content”>
<txp:body />
</div>
</txp:article>
</div>
</div>
Last edited by helmz (2010-09-16 22:49:10)
Offline
#17 2010-09-16 22:51:30
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,315
Re: General help
Offset 0 should be 1, like Els posted.
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
#18 2010-09-16 22:56:06
- helmz
- Member
- Registered: 2010-09-14
- Posts: 65
Re: General help
Oh oh! True! Sorry, my fault lol. Now running, so nice :D. My site is starting to look as a site haha, wont be possible without your help.
Offline
#19 2010-09-16 23:41:12
- helmz
- Member
- Registered: 2010-09-14
- Posts: 65
Re: General help
I dont know how but I inserted a mail, just one, dont know if I changed sth but I cant insert anyone more… I remember you the code
Im trying to insert data to mysql, I proced like this:
<form method="post" action="datadb.php">
mail: <input type="text" name="email">
<input type="submit" name="valider" value="Send">
</form>
datadb.php(located in root):
$email = $_POST['email'];
mysql_connect('host' , 'user', 'pw');
mysql_query("INSERT INTO email (email) VALUES ('$email')");
Ty
Last edited by helmz (2010-09-16 23:42:35)
Offline
Re: General help
Again, have a look at the mem_simple_form plugin. I haven’t used it myself, but I expect it would make this much easier.
Code is topiary
Offline
#21 2010-09-17 10:06:21
- helmz
- Member
- Registered: 2010-09-14
- Posts: 65
Re: General help
offset= 1 can be used only for one element or i can make more articles, I created a third article but it just changed for the 1st one, and the first one took the 2nd place
Last edited by helmz (2010-09-21 11:53:04)
Offline