Found this content helpful? Log in or sign up to leave a like!

How do I caption an image?

Jump to solution
Julia_L
Community Member

When I embed an image into a Canvas page, I would like to add a caption (not just alt text), sometimes with an attribution and/or link to the image's source. Is that possible?

Labels (1)
0 Likes
1 Solution
Gabriel33
Community Participant

It's hard to troubleshoot without seeing the code, but given that the image is to the right, you likely chose to "right align" it.

I tried it myself, and it changes the code to:

<figure>
<img style="float: right;" src="url" alt="alt text">
<figcaption>"caption text"</figcaption>
</figure>

 

And indeed, the image goes to the right, but the caption stays in the left.

To fix it, I moved the style="float: right;" property to the figure, which covers both the image and the caption:

<figure style="float: right;">
<img src="url" alt="alt text">
<figcaption>"caption text"</figcaption>
</figure>

 

View solution in original post