The tag has no wiki summary.

learn more… | top users | synonyms

5
votes
2answers
844 views

Are captions stored anywhere?

In regards to my previous question about shortcode captions, it doesn't appear to me that the actual text of a caption is stored anywhere other than in the post content within the shortcode itself. I ...
4
votes
1answer
58 views

Multi user site and image captions

On multi user sites when authors select images from the media library they can choose images that other authors have uploaded. The problem is that they can edit the caption and it changes it for both ...
3
votes
2answers
2k views

make Wordpress image captions responsive

This webpage contains images inserted by Wordpress. The code used to insert the first image is: [caption id="attachment_887" align="alignnone" width="604"] <a ...
3
votes
1answer
43 views

Alter media caption/description conflict in Wordpress?

When uploading an image, Wordpress reads the description meta data from the jpg via wp_read_image_metadata and inserts it into the post_content field when adding the attachment via media_handle_upload ...
3
votes
3answers
907 views

How to add a link in a image's caption?

I would like to add a link to the caption of a photo in one of my posts. I can type in the HTML for the link in the caption, but when I publish the post the link gets removed. How do you add a link ...
2
votes
3answers
3k views

Remove image caption from post excerpt

I am currently using a wordpress plugin called "limit-posts" to better customize my post excerpts. The only issue I have is the excerpt is including the caption text from the image that is within the ...
2
votes
3answers
616 views

Caption in Page adding unwanted 10px to width

I'm trying to create an image with a caption in a Page I'm working with. In the image options, I have it aligned right, with an image width of 220. Without the caption I have no problems, however with ...
2
votes
1answer
3k views

Get Image Description

I'm trying to make a post split in 2 columns. The first and left one is going to be any image inside the post, and the second and right one will be the_content() (excluding the images). So as of now ...
2
votes
1answer
1k views

Add extra class to wp-caption?

How do you add a new class to the HTML generated when an image with captions is added? For example, from this: <div id="attachment_xyz" class="wp-caption alignleft"... to this: <div ...
2
votes
1answer
285 views

Is there a way to define a default caption to all uploaded images

As the title of this answer say, I want to define a default caption to all uploaded images in my WordPress... Is there a way to do something like this?
2
votes
1answer
152 views

Include captions

I'm using the Meta Box plugin, everything works fine. I'm using it to create gallery function on some custom post type, and I'm able to display the uploaded images using this code: global $wpdb; ...
2
votes
1answer
163 views

Multi-line captions on attachments

How can I change the 'Caption' text input to text area, to allow for multi line captions on media uploads?
1
vote
2answers
307 views

Nested Shortcode Inside [caption] Doesn't Process

Captions in wordpress do not support nested shortcodes at the moment (v3.6). So, If I do write [caption]<img src=""> I love my [city][/caption] Where city is suppose to be processed but it ...
1
vote
1answer
247 views

How do themes render caption texts in extended markup (e.g. “wp-caption” paragraphs)

I've created my own theme based on a very lean template. My theme is not parsing the [caption]...[/caption] markup to the correct html. It's just showing the text without any markup around it. Here ...
1
vote
3answers
2k views

HTML tags in Wordpress image caption

I'm developing a client website with Wordpress (3.3) but have found that the image caption feature strips out any HTML tags. The resulting caption is plain text which makes proper image crediting ...
1
vote
1answer
570 views

Getting Featured Image Caption to Only Show if Populated

Good evening! I'm trying to hide the featured image caption from showing. Currently, it'll show build the div (but not populate it because it's empty). What I'd like to do, ideally, is only show the ...
1
vote
3answers
764 views

Caption shortcodes not including caption as attribute

I recently installed the bonpress theme and am having trouble with the captions showing correctly. The more I try to understand how captions are supposed to work in Wordpress, the more I suspect ...
1
vote
2answers
2k views

Include caption underneath post images

Hello I've been struggling for ages trying to find a solution for this. Basically I just want to retrieve all images from a post and display a caption underneath. Here is the code i'm using: ...
1
vote
1answer
139 views

Captions for More Fields groups, not just individual fields

I'm using More Fields to create some meta boxes on my custom post type. Is it possible to have a caption for each "group" of fields in the More Fields options? I would like to provide some basic ...
1
vote
1answer
9 views

Forcing max-width for image captions

I've implemented a filter to my image captions based on this question I asked a few days ago. How can I slip into the caption the css style of max-width as well? I think it can be done with ...
1
vote
1answer
125 views

How do I remove featured images and captions from a wordpress RSS feed?

I'm trying to remove featured images and captions from my feed and struggling to do it. As another question has identified it is very difficult to format captions and so as a newsletter feed I want to ...
1
vote
1answer
90 views

Can't insert caption into image

You can see live example here. When I add a caption into the image, it doesn't show at all! I've added the caption to the image as you can see in the next picture but it doesn't show as you see ...
1
vote
1answer
182 views

Remove inline width from figure

I add an image with caption to my page and need to increase <figure> width. But wordpress is adding an inline width. [caption id="attachment_44" align="alignnone" width="216"]<a href="image ...
1
vote
0answers
99 views

Way to add captions to gallery images by code

I am creating posts by using wp_insert_post function. It works fine as I provide values in array required. Sometimes it is required to create a post having gallery. Without any problem, it also works ...
1
vote
0answers
430 views

Image caption with apostrophe breaks the text with qTranslate [closed]

I created my own theme and I use on two different websites, along with a very few plugins (among them, qTranslate!). I noticed that recently (I don't think it was happening before) that all my image ...
0
votes
2answers
6k views

Displaying an image's alt title and caption inside a fancybox window. Working, but showing the same alt and caption for each image

I've been at this for hours so maybe someone here can help :) Basically I have a fancybox gallery that loads images attached to a post. As you can see below, I want to echo either the image's caption ...
0
votes
1answer
1k views

Displaying caption with featured image

I'd like to display captions with my featured images. This is another feature that should be available by default but for some reason is not. There are a few routines out there that claim to ...
0
votes
1answer
106 views

XML-RPC: How to add media caption to uploaded image?

I need to migrate non-WP data from an SQL database to posts in WP, and thought that using XML-RPC in a closed environment before deploying was a smart solution. This is my first WP project, so I'm ...
0
votes
2answers
93 views

How to check if there is image title, caption, description?

I use this code to display featured image title, caption (excerpt), description (content): echo get_post(get_post_thumbnail_id())->post_title; echo ...
0
votes
1answer
61 views

WP Gallery showing captions twice

I am using standard WP gallery to display images. I have added caption to every image, image title was not changed so it is same like file name. When I open one image in gallery it shows caption text ...
0
votes
1answer
99 views

Automatically add image caption with values from a post parent field?

i have a custom dropdown field on post and i would to get the value from that custom field and insert it on each image caption field uploaded to the current post. I have been looking for a way to do ...
0
votes
1answer
735 views

PHP code to call image Caption, Alternative Text, and Decription?

Is there a Wordpress PHP code to call an image Caption, Alternative Text, and Decription? I have several images with Titles, captions, alt text and Description fields filled and would like to display ...
0
votes
1answer
327 views

Custom caption output for custom image size

I've done a lot of searching and have found out how to customize the img_caption_shortcode oputput. What I can't seem to figure out how to do: Add a specific class to the caption's output if a ...
0
votes
1answer
439 views

Random home page background images with caption text

all. I am developing a Wordpress theme and I need to have a random background image display on the home page with specific text for each image. I have installed the Background Manager plugin ...
0
votes
1answer
1k views

How to limit post content and remove image caption from it

I am using this function to limit the content in my themes. But the problem is whenever I call the function, it also displays the image caption. I want to remove the image caption when calling ...
0
votes
3answers
293 views

How to edit caption for images and exclude it from excerption query?

I have 2 questions for caption for images: - how to edti them with bold, italics and so on? I do it, but it doesn't work. - if the image is first, how to exclude caption from excerpt in query ...
0
votes
1answer
235 views

Display a post attachment depending on the caption

I would like to display automatically a post attachment (PDF) depending on the language of my blog (french and english). When the post is displaying in french version, I would like display the french ...
0
votes
2answers
1k views

How to add line breaks inside Gallery Captions

I am using this excellent piece of code to insert a line break in single image captions by way of inserting a pipe character... Now I would like your help to try to incorporate this into the gallery ...
0
votes
1answer
259 views

add image caption

I would like to add caption to a image I just uploaded through a from. So I have the attachment id and the caption text in a variable. I found wp_update_attachment_metadata in wordpress codex .. but ...
0
votes
1answer
2k views

Turn off image captions in gallery view?

I've set up my loop-attachment.php to show the gallery of thumbnails above the main, selected image using this code from the WordPress Codex: <?php $gallery_shortcode = '[gallery id="' . ...
0
votes
3answers
479 views

Style wordpress image captions in RSS

My WordPress site includes the full article in its RSS feed. This includes the text of the post and basic formatting. It also includes post images and their captions. The problem is that my captions ...
0
votes
1answer
806 views

How to display a shortcode caption somewhere other than the_content

I want to disable shortcode captions for posts in one of my themes, and display the content elsewhere, such as in a sidebar. The images aren't uploaded to wordpress, but they're linked-to using the ...
0
votes
0answers
10 views

only first caption showing for attachment in Wordpress

ok I'm using the below code to generate caption for my attachments. The problem is if I have multiple images in a single page, the caption for first image shows for all the images. like if I have ...
0
votes
1answer
41 views

Wordpress Caption Formatting

I'm trying to create a custom wordpress theme. Everything has gone fine, except image formatting in post content. Image captions are not displaying properly in newly created theme. I have already ...
0
votes
1answer
44 views

echo image caption

I am attempting to echo out my image captions in a Bootstrap Carousel. I have managed to get my images to display but unable to display my captions. I have attempted to use wp_get_attachment_metadata ...
0
votes
0answers
29 views

Custom caption/image shortcode disappears after switching between text-editor and visual-editor

I've written an custom shortcode for images. I use the filter image_send_to_editor to modify the inserted html. My code (mostly copied from the core) looks like this public function send_to_editor( ...
0
votes
1answer
68 views

Move captions under gallery images in twenty fourteen theme

The new twenty fourteen theme will only show captions on top of gallery thumbs. Is there something I can do in the functions (or copy from twenty ten) to make them visible all the time and show up ...
0
votes
0answers
120 views

Remove Captions from Custom Gallery function.php

I like to prevent captions from being outputted in my custom gallery function. I could easily just hide it using CSS but it doesn't feel right. The caption is being sent from media.php this line. ...
0
votes
1answer
163 views

How to add 'data-caption' inside an anchor tag

bellow is custom gallery code. function custom_gallery_shortcode( $attr = array(), $content = '' ) { $attr['itemtag'] = "li"; $attr['icontag'] = ""; ...
0
votes
0answers
47 views

Drag images with caption in WP editor

Whenever I insert an image without a caption in the post, the editor makes it an object that I can select and move around / scale. Whenever I insert an image with a caption, it inserts fine. I can ...