<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
I haven't been following this discussion, so sorry if this isn't
what you were asking, but this is what I do in ALL my themes to make
the wp-caption div the same width as the img:<br>
<br>
<pre><tt>function theme_prefix_wpcaption($x=null, $attr, $content)</tt></pre>
<pre><tt>{ </tt></pre>
<pre><tt> extract(shortcode_atts( array( 'id' => '', 'align' => 'alignnone', 'width' => '', 'caption' => '' ), $attr));</tt></pre>
<pre><tt> if ( 0 >= (int) $width || empty($caption) ) {</tt></pre>
<pre><tt> return $content;</tt></pre>
<pre><tt> }</tt></pre>
<pre><tt> $id = $id ? 'id="' . $id . '" ' : '';</tt></pre>
<pre><tt> return '<div ' . $id . 'class="wp-caption ' . $align . '" style="width: ' . $width . 'px">' . $content . '<div class="wp-caption-wrapper"><p class="wp-caption-text">' . $caption . '</p></div></div>';</tt></pre>
<pre><tt>}</tt></pre>
<pre><tt>add_filter('img_caption_shortcode', '</tt><tt><tt>theme_prefix_</tt></tt><tt>wpcaption', 10, 3);</tt></pre>
<br>
<br>
On 4/21/11 10:16 AM, Towfiq I. wrote:<br>
<span style="white-space: pre;">> @emil<br>
> <br>
> But the twenty-ten theme is rendering the same thing. The
caption<br>
> width is automatically added by wordpress and I am not able
to<br>
> override the default width. :/<br>
> <br>
> Any suggestion?<br>
> <br>
> <br>
> -- Towfiq I.<br>
> <br>
> <br>
> <br>
> _______________________________________________
theme-reviewers<br>
> mailing list <a class="moz-txt-link-abbreviated" href="mailto:theme-reviewers@lists.wordpress.org">theme-reviewers@lists.wordpress.org</a> <br>
> <a class="moz-txt-link-freetext" href="http://lists.wordpress.org/mailman/listinfo/theme-reviewers">http://lists.wordpress.org/mailman/listinfo/theme-reviewers</a></span><br>
</body>
</html>