Reputation: 21
I'm a student making a website for my assignment and I'm working on a contact form as seen here: http://www.brightpixelstudios.co.uk/contact/
I'm trying to get the border surrounding the contact form to take up only the width necessary and not 100% of its parent container.
The container has floating elements inside it, would this be what's causing the problem?
Is there any work around I could try?
Thanks in advance,
Will Whitehead
Upvotes: 1
Views: 1492
Reputation: 446
You have three options here:
.wpcf7{ float: left }
.wpcf7{ display: table }
.wpcf7{ display: inline-block }
All of which will cause the contact form to take up the space of its children, and not its parent. It really depends on what you're after or what suits the needs of that particular page.
Upvotes: 1