Jump to content

Place on Top


ReptiGuy
 Share

Recommended Posts

I am trying to put a title above each of my pictures so I am using the <h1> tags and it is working great except for the top picture.When I used the <h1> tags on the top picture it lifted the red area up and there was a blue space in between the red and white area. To fix this I switched the <h1> tags to span tags and on the css sheet I put font-size: 2em; and font-weight: bold; and this made it look like it was in the <h1> tags but it put the title beside the picture.How do I make it so the title is above the picture?You can see what happened here: http://mymanager.site40.net/spanishproject.html

Link to comment
Share on other sites

Check for a <p> tag, maybe the picture would be inside a paragraph.But if this is not the case, why don't you make your page with the error so we can see what you're saying.Just by placing the H1, a <br /> and then the picture would be enough.

Link to comment
Share on other sites

I am trying to put a title above each of my pictures so I am using the <h1> tags and it is working great except for the top picture.When I used the <h1> tags on the top picture it lifted the red area up and there was a blue space in between the red and white area. To fix this I switched the <h1> tags to span tags and on the css sheet I put font-size: 2em; and font-weight: bold; and this made it look like it was in the <h1> tags but it put the title beside the picture.How do I make it so the title is above the picture?You can see what happened here: http://mymanager.site40.net/spanishproject.html
Don't use <h1> - it's purpose is to give the major definition/description/title for the page. <span> is for inline styling (inline in this case is within a line) and not the right choice either. What I would do is have a <div> that contained the title and the image floated next to the rest of the images. If you need help, let me know.
Link to comment
Share on other sites

Can you show your CSS style sheet? At least the part that shows how you've styled the picture/title that is broken and one or more that work correctly. And now that I've seen your site, I think I was correct in recommending H1 for the school name. While the others are correct that multiple h1 tags is a semantic nono, another level of H tag would not be inappropriate for the words over your pictures. Perhaps h2 or h3.Anyway, seeing the CSS would help determine what you need to add or remove to get your words over your picture.EDIT: I got an addon that let me see your CSS.I made this change and everything looked kosher.

.background2 {  background-color: #fff;  border: medium solid;  border-top: none;  text-align: center;  padding: 20px;}

<h2>Clase De Matemáticas</h2>	<image src="http://i289.photobucket.com/albums/ll216/Reptile_Guy_Mr_Nick/mymanager/mathsymbols.jpg?t=1227820242" id="math"/>										<hr>

I also changed your other <h1> tags to <h2> tags to continue the flow. you can add styles to <h2> to change the size, color, etc of the font if you are not satisfied with how it looks.

Link to comment
Share on other sites

Create an account or sign in to comment

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

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...