Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7957473
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T04:15:18+00:00 2026-06-04T04:15:18+00:00

I have a div with span4. when I add class with padding to that

  • 0

I have a div with span4. when I add class with padding to that div(my_background_plate), I no longer get 3 divs in a row but 2 (that padding pushes the last span4 to a new row). How to compensate?

 16   <% @projects.each do |p| %>
 17     <div id="projects" class="my_background_plate span4">
 18       <h3>
 19         <%= link_to p.name, project_path(p) %>
 20       </h3>
 21       <p>
 22         <%= p.description %>
 23       </p>                 
 24       <img src="http://placehold.it/205x140" alt="" class="thumbnail">
 25       <p>
 26         <% p.users.each do |u| %>       
 27           | <%= u.name %>
 28         <% end %> |        
 29       </p>
 30     </div>
 31   <% end %> 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T04:15:18+00:00Added an answer on June 4, 2026 at 4:15 am

    I found the answer whill wrestiling with it a bit. The whole magic is to leave the div with span class free from you custom classes and add them below in a separate div like below. 🙂

     17     <div class="span4">    
     18       <div id="projects" class="my_background_plate">
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following code in a php page <div class=vmenu> <div class=first_li><span >Add
I have a field like the following: <div class=control-group> <label class=control-label for=lname>Last Name</label> <div
So i have this structure <div class=accordionContent> <form action=/make_requests class=make_request method=post><div style=margin:0;padding:0;display:inline><input name=authenticity_token type=hidden
At the top of my page I have a div that spans the page,
I have a div with a span <div id=div1> <span class=>hello</span> </div> When i
I have a container DIV which contains several block-DIVS. Every block-DIV contains SPAN items
I have a div that has a span inside that will display a message
I have <span> inside a <div> , like so: <div id=#mydiv> <a href=#>Hello</a><span class=myImageArea></span>
I have the following html markup: <div class=wrap_select> <span class=select id=selectdateRange>Today, 25 March, Sun</span>
I've a doubt. Lets consider that we have a div of width 200px. If

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.