Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2004-12-25 07:35:51
- beholder
- New Member
- From: New Jersey, USA
- Registered: 2004-12-05
- Posts: 3
looking for plug in... unique link list inside an article.
Ok, this is hard to explain, and maybe there is a solution already… try to follow me.
I want to end every article with a list of sources (since I am going to be doing a lot of news readings). it will be in its own div (so I can style it a little differently), and every article will have, of course, its own unique list of articles.
I would like to add these links everytime I am composing an article, so it should be in its own tag <code><txp:sources /></code> maybe? I could wrote the sources my self for each article… kind of like pasting an article inside an article (which I can’t do.)
let me try to describe it again visually:
TITLE OF THE ARTICLE HERE
date
body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article
<b>
list of sources
source 1….
source 2….
source 3….
</b>
Permanent Link
comments
So, how do I do that? any suggestions?
Last edited by beholder (2004-12-25 07:38:18)
Offline
Re: looking for plug in... unique link list inside an article.
Actually you can.
If you create an article with the sources you can insert it to the other article by writing this:
<code><txp:doArticle id=“xxxx” /></code>
The <code>xxxx</code> is changed to the id of the article with the sources.
Create a section for the sources (you don’t need to create a file for it if you don’t want it), exclude it from the site search etc.
Just to know: If you do a search for the text of the sourcearticle it will not find it.
Plugins:
ob1_advanced_search 1.032b, ob1_search_score 1.0, ob1_pagination 2.5, ob1_title 4.1, ob1_modified 2.1
“Let your plans be dark and as impenetratable as night, and when you move, fall like a thunderbolt.”
— Sun Tzu
Offline
#3 2004-12-26 00:23:41
- beholder
- New Member
- From: New Jersey, USA
- Registered: 2004-12-05
- Posts: 3
Re: looking for plug in... unique link list inside an article.
Alright, sounds good.. never heard of that tag before. How do I know what is the article id? where do I find that? I am going to put this tag inside the article form, right?
Update:
this is a good idea. what I did is to add the <code><txp:doArticle id=“xxxx” /></code> in the body of the article, and there’s a new <code><div></code> inside my article, which is exactly what I want.
Here are the two problems:
1.) I have to publish the source article in order to use it with the do article tag. As a result, it shows <i>on top of the original article</i>, as a post of its own.. I really don’t want that to happen. Is there a way to “force” text pattern to show a hidden article, or something of the sort?
2.) I want to have access to that div which TXP creates for my sources article, because I want to be able to play with its style in my stylesheet. Right now it looks just like a “normal” article, but I need it to be a “sub” article.
I am going to play a bit more.
Thanks for the help!
Last edited by beholder (2004-12-26 00:40:56)
Offline
Re: looking for plug in... unique link list inside an article.
The article id can be found when you hoover over a link to edit an article in the admin in the status field of the browser. It clearly states ID=xxxx.
You can put this tag anywhere. In the article form or directly into the article body.
And it’s not a documented tag since it is not supposed to be used as a tag. It’s the function used “inside” TXP to handle an article call. But all functions can be used as tags so …
Plugins:
ob1_advanced_search 1.032b, ob1_search_score 1.0, ob1_pagination 2.5, ob1_title 4.1, ob1_modified 2.1
“Let your plans be dark and as impenetratable as night, and when you move, fall like a thunderbolt.”
— Sun Tzu
Offline
#5 2004-12-26 01:53:06
- beholder
- New Member
- From: New Jersey, USA
- Registered: 2004-12-05
- Posts: 3
Re: looking for plug in... unique link list inside an article.
Hmmm. Breakthrough?
I am using <code><txp:linklist category=“xxx”></code> in my article.. what I am going to do is to insert, manually, every end of article the div for my sources and then the name of the link list.
For example:
———————————————-
body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article body of article
<code>
<div id=“sources”>
<txp:linklist category=“the category made just for this article”>
</div>
</code>
———————————-
I think that’s the best idea so far… it’s a little anoying to write this manually each time, but hey, I have to insert the links in anyways… I am also worried that with time my link categories will last from here to China.. is that a problem with TXP? Is there a limit?
I am going to experiment….
Last edited by beholder (2004-12-26 01:53:33)
Offline