Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2008-02-06 08:23:24

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: Image caption

Actually, you don’t need to worry about breaking anything, since the tag could detect whether you have supplied a form or not. If you have, use it. If not, use the existing defaults.

e.g:

<txp:image id="122" form="plain_image" />
<img src="<txp:image_url />" width="<txp:image_width />" height="<txp:image_height />" alt="<txp:image_alt />" title="<txp:image_description />" />

Offline

#14 2008-02-14 12:18:32

kevinmcdougall
Member
Registered: 2007-02-08
Posts: 55

Re: Image caption

Why not use something like the rss_thumbpop plugin if you want to display captions in an image gallery?

Offline

#15 2008-02-14 14:11:11

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,060
Website GitHub Mastodon Twitter

Re: Image caption

Hi Kevin, the discussion here gears towards achieving certain functionalities using proposed core tags. It is true that rss_thumbpop and a series of other image plugins do have functions to display the caption but it would also be great if txp had its own caption tag too.

Last edited by colak (2008-02-14 14:11:34)


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#16 2010-05-12 03:19:12

laptophobo
Member
Registered: 2010-03-01
Posts: 216
Website

Re: Image caption

So, the short answer here is that the “caption” option within Images does not work.


Living the Location-Independent Life: www.NuNomad.com

Offline

#17 2010-05-12 23:25:09

masa
Member
From: Asturias, Spain
Registered: 2005-11-25
Posts: 1,091

Re: Image caption

Well, there never has been a caption attribute or <txp:image_caption /> tag, if that’s what you mean.

Offline

#18 2010-08-16 05:49:07

Bijay
Member
Registered: 2010-07-02
Posts: 17

Re: Image caption

hi all.. I am wondering if any body could help me to keep the caption on the image,… Those images are form the image category, and used javascript file to make them sliding.. javascript goes like this

<script type=“text/javascript” src=“http://ajax.googleapis.com/ajax/libs/jquery/1.4.1/jquery.min.js”></script>

<!— include Cycle plugin —>
<script type=“text/javascript” src=“http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.2.74.js”></script>

<!— initialize the slideshow when the DOM is ready —>
<script type=“text/javascript”>
$(document).ready(function() { $(‘.slideshow’).cycle({ fx: ‘scrollUp’ // choose your transition type, ex: fade, scrollUp, shuffle, etc…

});
});

</script>

Caption text in the images with those text get rolls..

For ex: http://www.summit-nepal.com/

Offline

#19 2010-08-16 10:58:56

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: Image caption

If you can use the upm_image plug-in to call the images it has an image-caption tag to call the caption from the “Images” tab. Use the main plug-in tag as a wrap-tag to create the format you need for the slider.

Last edited by thebombsite (2010-08-16 10:59:35)


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#20 2010-08-17 04:39:37

Bijay
Member
Registered: 2010-07-02
Posts: 17

Re: Image caption

Does “upm_image” plugins support the image to get roll like we have some rolling option “fade”, “scrollUp”, “shuffle”?

Offline

#21 2010-08-17 07:43:47

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,060
Website GitHub Mastodon Twitter

Re: Image caption

Bijay wrote:

Does “upm_image” plugins support the image to get roll like we have some rolling option “fade”, “scrollUp”, “shuffle”?

Hi Bijay,

It’s a question that should be asked in the plugin’s thread

—->ps. And back to the thread’s topic:) So much looking forward to HTML5


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#22 2010-08-17 15:03:48

thebombsite
Archived Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: Image caption

The upm_image plugin is not a gallery. It merely gives you more options to work with than the current <txp:image /> tag. If you want effects you will need to add them yourself. I have a little article that may be of interest to you.

Last edited by thebombsite (2010-08-17 15:04:49)


Stuart

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#23 2014-02-17 14:18:05

Destry
Member
From: Haut-Rhin
Registered: 2004-08-04
Posts: 4,909
Website

Re: Image caption

Mary wrote #170851:

FYI: caption is currently output as image title attribute, if you think it isn’t being used anywhere.

Well, I’ve just spent a fair amount of time getting to the end state of this, which is great, but realized (or rather, remembered, along with the other bad easter egg, escape="" for textile) that Txp’s image caption field is actually treated as the value for a title attribute. That’s disappointing because now the caption text is showing up twice in the UI, once from title hovers, and once for the actual figure caption used under images.

In my case, captions under images are sometimes like this for each image: Figure 1: Lorem ipsum and goes on for three long sentences to describe graph, chart, whatever. That’s not such an unusual use of real captions, I think.

So you can imagine how ugly those title popups look, and not very usable. Redundant, and no doubt annoying to people using screen readers.

I think we can all agree, at least I hope we can, that an image’s title="" attribute is not the same thing as a real piece of copy marked up as a figcaption. So I totally agree with Lee here, but two things need done, really:

  1. The existing “Caption” field needs to be relabeled to Title attribute (<txp:image_info type="title" />), because currently it’s totally frickin’ confusing.
  2. A new field needs created for an actual caption, and to make it explicitly clear, label the field Fig caption (<txp:image_info type="caption" />).

Then adjust this variable for figures/figcaptions so it’s actually spitting out the caption not the erroneous title attribute value.

As it is now, I don’t think it’s worth using the nice variable for figcaptions because it’s causing duplication of content (title popups being unnecessary in this case).

Offline

#24 2014-02-17 16:40:00

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,408
Website GitHub

Re: Image caption

Destry wrote #279019:

Txp’s image caption field is actually treated as the value for a title attribute.

Yes, it predates the caption / figcaption / figure concept in HTML, and is badly used in Txp.

As you suggest, this issue goes a bit deeper than just the tag itself. We need a new UI element on the Image Edit panel, and a corresponding database field to separate the title and caption, and then mirror those with the tag. In this case, I’m not sure if it’ll break backwards compatibility too much if the caption is changed to output the caption instead of the current title/caption combo.

There’s also one more spanner in the works: the planned image custom fields. At what point do the various image attributes (primarily name, title, and caption) go from being first class citizens in the database to being just attribute data? Is a caption a required field that we should always store against the image, like width and height are, or is it an optional thing that you don’t want to gum up the database on everyone’s installation? Same goes for title: it’s an optional HTML attribute after all, but moving it from being a first class attribute to a custom field would break too much unless we were very clever with the tag options to pull the right info from the custom field table for legacy installs. Quite messy, but there may be a way to do it with some lateral thinking.

Arguably a caption is required for some (most?) situations but, as you say, site images won’t need them for the same reason that the title isn’t much use for screen readers. Is this a candidate for allowing ‘site images’ to be separate from the ‘content images’ pool and they’re treated separately, or is that just too confusing?

So what’s the path forward here? I’m more than willing to take this on as an enhancement, because it’s been confusing for too long now. Just, how do we manage it so that we:

a) minimise breakage with existing image_info tag.
b) make the interface and tags consistent and usable going forward.
c) factor in potential image custom fields (providing I can manage it: major step forward this morning, btw!)

Thoughts?


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

Board footer

Powered by FluxBB