Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: Redirect to external articles
phiw13 wrote #339018:
How would that work in practical usage – e.g with the markup given above – article list, external link with
rel
and/ortarget
attributes, internal links just “plain“.
Dunno. Presently <txp:permlink />
does not accept rel
attribute, but sets rel="bookmark"
. We might imagine that for external links it becomes rel="external"
if it fits better. We could also somehow enhance the tag with this attribute.
As for target
, themes could use a bit of js to set target="_blank"
or whatever for external links. Ideas welcome.
Offline
Re: Redirect to external articles
etc wrote #339024:
Presently
<txp:permlink />
does not acceptrel
attribute, but setsrel="bookmark"
. We might imagine that for external links it becomesrel="external"
if it fits better. We could also somehow enhance the tag with this attribute.
Sounds good to me, and non-contentious if the link is outside the current site_url’s domain.
As for
target
, themes could use a bit of js to settarget="_blank"
or whatever for external links. Ideas welcome.
Yes! People have passionate opinions on whether a new tab/window should be spawned, so leave that to the site owner / designer.
TXP Builders – finely-crafted code, design and txp
Offline
Re: Redirect to external articles
etc wrote #339024:
Dunno. Presently
<txp:permlink />
does not acceptrel
attribute, but setsrel="bookmark"
. We might imagine that for external links it becomesrel="external"
if it fits better. We could also somehow enhance the tag with this attribute.As for
target
, themes could use a bit of js to settarget="_blank"
or whatever for external links. Ideas welcome.
Adding rel=external
by default in such case is a no-brainer I think. target="_blank"
should certainly not be set by default, hence I asked above – a way, txp-code-wise to differentiate between the 2 types of <txp:perm_link />
(e.g. being able to something similar to the code snippet given by Stef above).
I am no fan of wasting some js to inserting that attribute…
Where is that emoji for a solar powered submarine when you need it ?
Sand space – admin theme for Textpattern
Offline
Offline