Like our free content? Then you'll love our exclusive Club!
Divi Academy Membership gives you exclusive access to over 110 resources, including child themes, layouts, cheatsheets, tutorials, live training and member perks. And new content is added EVERY Monday!
Recipe #20 is something I initially thought was going to require some clever PHP editing, until I remembered the ‘odd’ and ‘even’ CSS pseudo classes. I had great fun with these and will definitely be using them more in the future. The best thing about this recipe is that it uses the automatic excerpt so if you have existing posts there is no need to go in and add manual excerpts, and not a bit of PHP in site ![]()
I had always intended Divi Soup to be a video based Divi tutorial site but in the beginning I had so many other things on my plate I just didn’t have the time to create a video as well. I plan to change that! So watch the video, get the code you need in the accompanying blog post, be sure to scroll to the bottom for your fabulous freebie, and let me know what you think in the comments!
You can view the demo here

So let’s get cooking!
Ingredients
The Divi Theme from Elegant Themes
An active child theme
Some existing blog posts or some demo content. Divi uses a default featured image size of 1080 x 675px, this should work with any size images but you are best to make them all the same size. Any size with the same aspect ratio as the default featured image size will avoid your images being cropped.
Cooking time
This should take you around 10 minutes max.
Preparation
The first thing we need to do is set up our section. So add a new section with a single column and then add the blog module.

Open the row settings and make the row fullwidth and set the gutter to 1, then Save & Exit.


Method
Next we need to configure our blog module. Open up the blog module and give it the following settings:
Layout: Fullwidth
Show Featured Image: Yes
Content: Show Excerpt
Read More Button: Yes
Featured Image Overlay: Off (well will set this in the CSS)
For the remaining settings you can choose whatever you like, this is all that’s needed for the layout to work.
Next click on the Custom CSS tab and give the module a CSS Class of ds-alternating-blog

Be sure to Save & Exit.
Now for the CSS. Add the following to your child theme stylesheet or Divi theme options custom CSS box.
/*Alternating blog layout*/
/*Set the effect for screen sizes 980px and larger*/
@media only screen and (min-width: 980px) {
.ds-alternating-blog .et_pb_post {
background-color: #fff;
margin-top: 0;
margin-bottom: 0;
padding: 30px;
}
/*Add some hidden content to clear the floats and make our posts site on their own row*/
.ds-alternating-blog .et_pb_post:after {
content: ".";
visibility: hidden;
display: block;
height: 0;
clear: both;
}
.ds-alternating-blog .et_pb_post h2 {
margin-top: 0;
}
/*This sets the odd post images to the left*/
.ds-alternating-blog .et_pb_post:nth-child(odd) img {
float: left !important;
overflow: hidden;
width: calc(50% + 60px);
height: auto;
padding-right: 30px;
margin: -30px 0 -30px -30px;
}
/*This sets the even post images to the right*/
.ds-alternating-blog .et_pb_post:nth-child(even) img {
float: right;
overflow: hidden;
width: calc(50% + 60px);
height: auto;
padding-left: 30px;
margin: -30px -30px -30px 0;
}
/*This sets the background color of the image ready for the hover effect*/
.ds-alternating-blog .et_pb_post img {
background:rgba(255,255,255,.75);
opacity:1;
-webkit-transition: opacity .25s ease;
-moz-transition: opacity .25s ease;
transition: opacity .25s ease;
}
/*This gives us the image opacity on hover*/
.ds-alternating-blog .et_pb_post img:hover {
opacity: .5;
}
/*This aligns the post text to the right on even posts*/
.ds-alternating-blog .et_pb_post:nth-child(even) {
text-align: right;
}
/*This sets the position of read more button on odd posts*/
.ds-alternating-blog .et_pb_post:nth-child(odd) a.more-link {
display: block;
clear: none;
margin-left: calc(50% + 30px);
}
/*This sets the position of read more button on even posts*/
.ds-alternating-blog .et_pb_post:nth-child(even) a.more-link {
display: block;
clear: none;
margin-left: calc(50% - 180px);
}
}
/*This styles the read more button*/
.ds-alternating-blog a.more-link {
border: 1px solid #000;
width: 150px;
color: #000;
margin-top: 20px;
padding: 10px;
text-align: center;
}
/*This styles the readmore button on hover*/
.ds-alternating-blog a.more-link:hover {
border: 1px solid #000;
color: #fff !important;
background: #000;
}
/*This changes the layout to stack posts on smaller screens*/
@media only screen and (max-width: 979px) {
.ds-alternating-blog .et_pb_post {
margin-bottom: 0;
}
.ds-alternating-blog .et_pb_post a img {
min-width: 100%;
}
.ds-alternating-blog .et_pb_post .entry-featured-image-url {
margin: -30px -30px 30px -30px;
}
.ds-alternating-blog .et_pb_post {
padding: 30px;
}
}
/*This fixes a small margin issue with the post meta on small screens*/
@media only screen and (max-width: 479px) {
.ds-alternating-blog .et_pb_post .post-meta {
margin-top: 10px;
}
}
And that’s it.
If you found this helpful please leave a comment and subscribe to my newsletter for all my latest Divi related content. ![]()
Michelle X





Hi Michelle, thanks for your nice recipe. It’s very helpful for my work. But I’d like to make my blog page using this Full-width Alternating Blog Layout with 2 columns in a row like “image | post | image |post” . (Now it’s in 1 column like “image | post”.) Can you get me any ideas? Thanks.
You can modify the grid layout in the Divi module with custom CSS
Hi Michelle, I’ve added this to a dev site i’m working on and while it looks great on the page, the featured image by default links to a blog page. I would prefer to remove the link from the image and just show what I have written on the alternating layout, but I’m not sure where I do that. Alternatively, if I did want to link through to the blog post itself, I can no longer use the builder, as that breaks the display on the alternating layout. Seems the easiest solution is to remove the link from the featured… Read more »
John, whether or not you use the builder on the single post page should not affect the main blog page, so maybe there is something else going on there.
For the image link, you can add pointer-events: none; to the featured image class and it will disable the link
This was simple to execute, however, when I add the CSS to my child style sheet it doesn’t work. I have added it to the Divi section and it works fine. Is there a way to have the page navigation align farther from the edges of the full width?
Try turning off static CSS and minification in Divi theme options and clear all of your caches. If that doesn’t work please run your CSS through csslint.net to make sure you have no errors
Thank you so much, Michelle. Exactly what I was thinking about.
Hi, thanks for this awesome soup dish. However, it doesn’t work for all devices on smaller screens even after turning of all plugins. The post have the 30PX space on smaller screens. Please advise, as I really like the layout and would love to use it.
Example: Stephanie on November 16, 2016 at 12:12 pm
Hi Michelle,
There has been a divi update and (I think) since then, my blogs don’t line up nicely any more. See http://www.astriddaans.nl/
What can I change in my CSS?
You alignment issue is because of the social sharing plugin you are using. You can add this CSS to fix it:
.addtoany_share_save_container {
clear: none !important;
}
I am not clear on what your issue on mobile is?
Hi ! Michelle , greetings.
I would be grateful if you write an article:
How to configure the display of the blog page as on image: https://cloud.mail.ru/public/FhLw/3c7FHU5ah
Interested page displaying exactly as in the photo unstyled CSS elements.
Thank you very much !
Andrey I will see what I can do, this should get you most of the way there https://quiroz.co/modify-the-divi-blog-fullwidth-layout/
Tu css is great. But i have a problem when i see him in Safari browser. I can read in the web that is a problem whit operator Calc in css. Could you create a solution for this?
You can check out this post here which has a couple of solutions. I don’t use safari so am unable to test it http://stackoverflow.com/questions/20443343/css-calc-not-working-in-safari-and-fallback
Hi Michelle,
There has been a divi update and (I think) since then, my blogs don’t line up nicely any more. See http://www.astriddaans.nl/
What can I change in my CSS?
The issue is actually coming from your social sharing plugin. You can add this which should fix it
.addtoany_share_save_container {
clear: none !important;
}
You are a genius! Thank you so much
This exactly what I was trying to do with a page and ended up creating a mobile section to handle the checkerboard. This will come in very handy for another site. Thank you for all you do for the community.
Thanks Michael
I have tried this but unfortunately it didn’t work for me.
The reason is that I have some video posts, and I believe your CSS does not take into account that some posts may not have featured images but videos instead.
I tried to select the video container in the CSS, but no luck, it may require some more tweaking to make it work.
This may be trivial to you.
Could you please update your CSS to work with video posts as well?
Thanks
David this tutorial is for standard blog posts, I will look to do a layout for video blogs in the future
Some “normal blogs” may eventually have another blog post type in there other than the standard blog post.
And when that happens the layout will be broken.
At least specify that this only works for standard blog posts and that one should be aware of adding other kinds of posts.
Anyway, I will look forward a video blog layout, but I would prefer if you made something that encompasses all kinds of posts .
I will see what I can do David
Hello!
I like these layouts, and I followed your recipes, but I miss layouts like these with a sidebar… Especially BlogMode needs sidebars, at least on my sites ;=)
Cheers and thank you for your work,
Connie
Thanks Connie. This one is specifically fullwidth but some of the other work with a sidebar
Thank you. I was looking for this!
Hi Michelle – is it possible to do something like this with Projects, as well?
Well a project is its own page Lisa so you can do pretty much what you want. However if you mean the portfolio module which displays the links to the projects then yes it should be possible. I have plans to work on some portfolio recipes soon
Thank you. I was looking for this! Will use it on my new blog. Thank you so much for your magic!
Welcome Emily
You’re a legend Michelle, seriously. I love this layout and the video is great – your voice is perfect!
What I like most though is that you’re still providing the written form – I watched the video because I’m in France, but once I’m back home I won’t have the bandwidth.
Hooray for providing the .json file!
Thank you, well done, three cheers to you for your great work!
Thanks so much Cath, hope you are enjoying the visit with your daughter
I adore this look, thank you Michelle!
You are most welcome Eileen
Thank you Michelle!, I have learned so much with you and your recipes
Welcome Madelein