Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#31 2006-01-31 02:47:06
- KurtRaschke
- Plugin Author
- Registered: 2004-05-16
- Posts: 275
Re: Code in article titles
> Anark wrote:
>And you could switch Textile off in case you’d need to print a cite tag in your title.
There’s already a Textile syntax for <cite>: ??citation?? (renders as citation). Is this in some way insufficient?
-Kurt
kurt@kurtraschke.com
Offline
#32 2006-02-03 05:24:39
- Anark
- Member

- Registered: 2004-08-14
- Posts: 101
Re: Code in article titles
Kurt, that’s good to know — I wasn’t aware Textile had a shortcut for the cite tag.
No, the shortcut wouldn’t be insufficient if it were allowed in titles, along with other inline markup.
Offline
#33 2006-02-03 06:06:04
- marknumberm
- Member

- From: Minneapolis
- Registered: 2005-11-29
- Posts: 46
Re: Code in article titles
You’re complicating the interface that way; the absence of interface clutter is one of TxP’s selling points.
Um, I don’t think it complicates it that much. It would be under advanced options, and if you were okay with all your un-styled, rss/email/xml-friendly titles being just the same as your regular titles but with any tags stripped off, you wouldn’t have to ever look at it — once again, just as “URL-only title” is now.
Or…
Maybe you wouldn’t have to deal with seeing it on a field any where on your interface. Maybe the tagged and tag-stripped versions of your title could just live in separate fields in your SQL database.
In fact, I wonder if they’re already saved that way; a title using <code>cite /cite</code> tags appears in italics on the internal article list (“Content > Articles” tab), even though the <code>cite</code> tags themselves are printed on the live site.
That, it would seem to me, is a bug.
But as long titles can appear rendered two different ways already, I would think that the code-parsed versions could show up in live article titles, just as they do now on the development side.
Last edited by marknumberm (2006-02-03 06:06:22)
Offline
#34 2006-05-28 14:06:44
- Yurodivy
- New Member
- Registered: 2004-10-29
- Posts: 9
Re: Code in article titles
Tracking through this thread, I’m very interested to know if any further development has occurred to allow for the formatting of titles. Any new news?
Offline
#35 2006-06-02 07:00:20
- dragonfey
- New Member
- Registered: 2005-12-26
- Posts: 2
Re: Code in article titles
Well I didn’t realize that using markup was impossible after I wanted bold for my article titles, and they happily showed up in the preview tab on the new article page. So I went and inserted mark-up on all my sticky pages, only to have it show the html on the finished product.
So why can it render ok in preview and not on the finished product?
Offline
#36 2006-06-03 04:50:43
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Code in article titles
The preview mechanism likely needs to be updated to remain consistent with the actual output. :)
Offline
#37 2006-07-09 18:48:21
- NyteOwl
- Member

- From: Nova Scotia, Canada
- Registered: 2005-09-24
- Posts: 539
Re: Code in article titles
I unthinkingly went ahead and following accessibility/semantic/best practices tried to use <code><acronym></code> in an article title. Following this I found this (and related) threads.
I have a suggestion – if permitting html tags in the article titles presents a problem for Textile parsing – how about enabling it for those of us that don’t use textile but raw html?
That is “if (no_textile) then display-as-proper-html”. Then Textile parsing wouldn’t be a problem.
Obsolescence is just a lack of imagination. / 36-bits Forever! / #include <disclaimer.h>;
Offline
Re: Code in article titles
<blockquote><blockquote>no seriously, an article NAME and article TITLE? like with category & sections?</blockquote>
This is not a bad idea, nardo. But it would be best if it happened by an automatic process.
Instead of having to write two different titles for every article (especially when many won’t need to be different), I would think there could be something like the functionality of the “URL-only title” field: you type in your article title as you want it to be styled with textile (or probably html, for that matter), and as soon as you click on “Publish,” a TITLE2 (or some such) field is automatically populated with that title minus all coding.
RSS, emails, etc., would get the code-less TITLE2; everything else would get the nicely styled one.
Would that work?</blockquote>
I’m coming late in the discussion but I think that this would be a very useful addition too.
My view:
Separation of title into two tags: <code>txp:title</code> and <code>txp:name</code>
where ‘title’ shows in the head (no html) and name shows in the body (html enabled)
possible use (remember I am no programmer) :)
if ‘name’ empty ‘name’=‘title’
or it can be used with the chh_if_data plugin
ie
<code><txp:chh_if_data><txp:name />
<txp:else />
<txp:title />
</txp:chh_if_data></code>
I recently had to publish a text where the title had a number pointing to a footnote. I know I could use a custom field except I want the ‘names’ of the articles to be searchable so that was out of the question. (basically I had to leave the link to the particular footnote out)
Last edited by colak (2006-07-10 06:22:12)
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
#39 2006-07-14 02:32:36
- NyteOwl
- Member

- From: Nova Scotia, Canada
- Registered: 2005-09-24
- Posts: 539
Re: Code in article titles
This hit me when I tried moving an article into txp that on the original site had the following in the title:
<code><acronym title=“American Telegraph and Telephone”>AT& #38;T</acronym><sup>& #174;</sup></code>
<br />
I have since hacked my taghandlers.php so that “function page_title” uses “return $out;” rather than “return escape_title($out);” and “function title($atts)” uses “ return $thisarticle[‘title’];” instead of “return escape_title($thisarticle[‘title’]);”
So far there seems to be no ill effects. Still can’t use markup in the article titles but at least it displays html entities now.
Last edited by NyteOwl (2006-07-14 02:57:27)
Obsolescence is just a lack of imagination. / 36-bits Forever! / #include <disclaimer.h>;
Offline