hello everyone,

I am creating a website but i need to put an image at the very top left of the page, there is always a gap between the edge and the image. I used this code,

<body leftmargin="0">

but it only moved the image along slightly more to the left.

Recommended Answers

All 5 Replies

yeap, cause you forgot about the top margin.. notice LEFT!

just use margin....

<BODY style="margin:0;">

Thanks, used that, but still image is not touching the side and top of the page, which, is the effect that i wanted. Any other ideas?

what is it doing then? did it move at all? maybe the image has a border around it? is it in a table? if you show some of the code I could better help you.

doesnt matter, i figured out what i did wrong

To do this via HTML:

<body topmargin="0" leftmargin="0" marginheight="0" marginwidth="0">

To do this via CSS:

<body style="margin:0px">
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.