Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Opportunity to add new attribute(s) into the <txp:image_url /> tag
Some javascript solutions refer to a “class” attribute for links in order to display photo galleries. Others use a “rel” attribute which is unfortunately not valid in HTML5 (e.g.: shadowbox.js). Furthermore, there is a rise of the HTML5 custom data attributes (“data-”).
So, what do you think about that?
Last edited by Pat64 (2014-11-06 12:42:16)
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Re: Opportunity to add new attribute(s) into the <txp:image_url /> tag
What’s wrong with using it as a single tag and rolling your own?
<txp:images category="gallery">
<a href="<txp:image_url />" class="linkclass" data-photographer="<txp:image_info type="author" />">
<txp:thumbnail />
</a>
</txp:images>
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
Re: Opportunity to add new attribute(s) into the <txp:image_url /> tag
:) :) :)
Perfect. It seems obvious I’ve got difficulties with this tag!
Thanks lot Stef.
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Re: Opportunity to add new attribute(s) into the <txp:image_url /> tag
And if you need to use that a lot in your body field, you can make an smd_macro out of it :-)
TXP Builders – finely-crafted code, design and txp
Offline
Re: Opportunity to add new attribute(s) into the <txp:image_url /> tag
Yep!
Thanks Jakob (good idea)
;)
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline