Jump to content

2 column form at different points - text fields and drop down select

Go to solution Solved by tuanphan,

Recommended Posts

Site URL: https://malenyvedicvillage.squarespace.com/

Hello community!! I am using the below code to have 'email' and 'phone' fields on the same line in this form...

/* 2 column form */
@media screen and (min-width:768px) {
div#block-yui_3_17_2_1_1663306565143_2737 {
.form-item.field.email {
    float: left;
    width: 49%;
    margin-right: 2%;
}
.form-item.field.email+div {
    float: left;
    width: 49%;
}
}
}

It works perfectly but I have also been trying to float the fields 'zip/postal code' and 'country' to no avail. 

I would also like to have the drop down select on the same line.... 'what is the reason for your interest?' and 'what is your budget?'

Please help. I have tried all sorts of other code snippets and can't get it to work. Site pw is : Maharishi

Many thanks for any help!!!!

Screen Shot 2022-09-27 at 10.22.44 am.png

Link to comment
  • Solution

Use this CSS

@media screen and (min-width:768px) {
div#block-yui_3_17_2_1_1663306565143_2737 .form-item:nth-child(n+5) {
    width: 49% !important;
    float: left;
    margin-right: 1%;
}
}

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Create an account or sign in to comment

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

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.