WordPress开发者和主题制作者的搜索引擎



img_caption_shortcode_width ›

Since3.7.0
已弃用n/a
apply_filters( 'img_caption_shortcode_width', $width, $atts, $content )
参数: (3)
  • (int) $width Width of the caption in pixels. To remove this inline style, return zero.
    Required: Yes
  • (array) $atts Attributes of the caption shortcode.
    Required: Yes
  • (string) $content The image element, possibly wrapped in a hyperlink.
    Required: Yes
查看:
  • img_caption_shortcode()
定义在:
文档:

Filters the width of an image's caption.

By default, the caption is 10 pixels greater than the width of the image, to prevent post content from running up against a floated image.





源码

$caption_width = apply_filters( 'img_caption_shortcode_width', $width, $atts, $content );