Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Advanced Search
  • 1

how to center a markdown block?


Posted (edited)

Site URL: https://www.lulucheng.com/writing

i added a markdown block so i could embed an email signup form for my Substack newsletter. this is the html code i received from Substack to do that:

<iframe src="https://lulu.substack.com/embed" width="480" height="320" style="border:1px solid #EEE; background:white;" frameborder="0" scrolling="no"></iframe>

however, when i paste this code into the markdown block editor, it left aligns the signup form (white box below the 'sign up' button):


how do i center the signup form on the page? i'm using the sofia template. 

thanks for any help or insight!

p.s. i removed the markdown block from https://www.lulucheng.com/writing for now, but the screenshot i've attached shows the issue i'm describing.

Edited by skiptomylu211

Share this post

Link to post

5 answers to this question

Recommended Posts

  • 0
On 4/18/2020 at 10:55 AM, derricksrandomviews said:

Push the block to the center using spacers on the left and right. Might just need one on the left. . 

how do i insert a spacer? (what’s the code i need to put)

Share this post

Link to post
  • 0
10 hours ago, derricksrandomviews said:

There is no code, just edit a page and add a spacer, just as you would add a text block or image block,  to the page and use it to move the markdown block. You will need to put the markdown block back up first of course. 


ah, i see. i added a spacer on either side, but it's still not centered. it's more obvious on mobile:


i think the problem is that the signup module itself is left aligned in the markdown block. and no matter how i resize the spacers on either side, i can't get it quite centered. is there a way to center the signup module within the markdown block (maybe using code)? 

Share this post

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

  • Create New...