How to fix "short" image captions (SilverStripe 3 websites only)

Created by Margie Wylie-Petruzziello, Modified on Thu, 11 Jan at 1:40 PM by Margie Wylie-Petruzziello

As of January 2023, these instructions apply only to All other sites have been upgraded.

Sometimes the box containing your caption will come out too short (see below).  This happens when your caption is shorter than the width of the image.

To fix this issue you have two choices:

1) Lengthen your caption, or
2) Make a tiny edit to the HTML.

Method 1: Lengthen Caption

When you lengthen the caption, the box grows along with it until it reaches the full width of the photo (below).

Method 2: Make a Tiny HTML Edit

  1. Open the HTML by clicking the “HTML” button in the formatting controls of the content window.

  2. Search for “caption” by pressing the option key and the “f” key (⌘-f) simultaneously. (make sure your browser window is active or you will wind up searching your file system instead of the page).
  3. The text will look something like this: <p class=”caption right”>Robert Baraldi</p> or <p class=”caption rightAlone”>Robert Baraldi</p>
  4. Delete the alignment instruction word (either right, left, rightAlone, or leftAlone) so that the HTML reads <p class=”caption”>Robert Baraldi</p>
  5. Click “Insert” and “Save” to preview the page.

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article