Center twitter post

Hi there,
Can anyone help me to center or fix the width of my tweets?
Here is my website:
and here is the code:

Thanks in advance

Please find help for HTML and/or CSS topics on or an other website dedicated to these topics. This forum here is more for Hugo related issues.

Regarding your issue: You did not say what you mean by “fix”. You can’t change an embed tweet to 100% width, because Twitter basically finds ways to kill this off again and again. The width is more or less fix.

So what you can do is center the embedded tweet. You can center ANY div by using margin: 0 auto; on them (or margin: 10px auto 10px; in your case). The div to apply this to is .twitter-tweet. Put this in your stylesheet and it will be centered.

The auto in margin works only on the left and right margin of block level elements but it’s standard in all engines/browsers.

1 Like

Thanks a lot.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.