I am writing a quiz in html and I would like to insert a consistent blank vertical space between questions (like one would use vspace{3 cm} in LaTeX).

For example:

<html> <body> <p> This is the first question? <!-- this is where I want about 3 cm of space --> </p> <p> This is the second question? <!-- this is where I want about 3 cm of space --> </p> </body> </html> 

Is there a straight forward way of doing this using just html and css?

4 Answers

Read up some on css, it's fun:

<style> .bottom-three { margin-bottom: 3cm; } </style> <p> This is the first question? </p> <p> This is the second question? </p> 
1

While the above answers are probably best for this situation, if you just want to do a one-off and don't want to bother with modifying other files, you can in-line the CSS.

<p>This is the first question?</p> 

i always use this cheap word for vertical spaces.

 <p>Q1</p> <br> <p>Q2</p> 
1

write it like this

p { padding-bottom: 3cm; } 

or

p { margin-bottom: 3cm; } 
3

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy