Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2009-08-15 14:36:45

cmscritic
Member
From: Edmonton, Alberta, Canada
Registered: 2009-07-09
Posts: 29
Website

Call article by article id.

Is it possible to call an article by article id? For instance, linking to it using the ID as opposed to the full url?

Offline

#2 2009-08-15 15:34:59

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: Call article by article id.

You can:

<txp:permlink id="123">some words</txp:permlink>

And if you need to “access” more info inside the article, you can:

<txp:article_custom id="123"><txp:permlink><txp:title /></txp:permlink></txp:article_custom>

La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

#3 2009-08-15 15:49:25

cmscritic
Member
From: Edmonton, Alberta, Canada
Registered: 2009-07-09
Posts: 29
Website

Re: Call article by article id.

Thank you very much.

Offline

#4 2009-08-16 21:42:39

ndrwtrvrs
Member
From: London
Registered: 2008-04-03
Posts: 25
Website

Re: Call article by article id.

Mike, another way of doing this is through Stef Dawson’s simple but splendid smd_short_url plugin – this has been getting a bit of attention recently as a responsible and sensible way of creating shortened Twitter-friendly links. This gives you urls in the format of site.com/id, where id is the article’s ID

Offline

Board footer

Powered by FluxBB