-
1. Re: Centering a Picture /Photo
MurraySummers Sep 1, 2010 7:32 AM (in response to GESYMSB)Why is it absolutely positioned anyhow?
Why not this?
img {
width:520px;
height:335px;
margin:0 auto;display:block;
}
</style>
</head><body>
<img src="DVC00166.JPG">
</body> -
2. Re: Centering a Picture /Photo
bemdesign Sep 1, 2010 7:36 AM (in response to GESYMSB)I'd avoid absolutley positioned elements for layout - only use them when you know what you know exactly what you're doing with them and understand HTML layout. But try this:
<style>
.wrapper{
width:960px;
margin:0 auto;
text-align:center; /*centers content within the div*/
}
.wrapper img{
margin:240px;
/*this is exactly half of 480px which is half of 960 pixels - thus helping to center the image within the wrapper div and giving equal margins all over*/
}
</style>
</head>
<body>
<div class="wrapper"><img src="DVC00166.JPG">
</div>
</body>Hope this helps.
-
3. Re: Centering a Picture /Photo
GESYMSB Sep 1, 2010 10:52 AM (in response to bemdesign)Thanks ! I will try that......
Date: Wed, 1 Sep 2010 08:36:08 -0600
From: forums@adobe.com
Subject: Centering a Picture /Photo
I'd avoid absolutley positioned elements for layout - only use them when you know what you know exactly what you're doing with them and understand HTML layout. But try this:
<style>
.wrapper{
width:960px;
margin:0 auto;
text-align:center; /centers content within the div/
}
.wrapper img{
margin:240px;
/this is exactly half of 480px which is half of 960 pixels - thus helping to center the image within the wrapper div and giving equal margins all over/
}
</style>
</head>
<body>
<div class="wrapper">
!DVC00166.JPG!
</div>
</body>
Hope this helps.
>
-
4. Re: Centering a Picture /Photo
GESYMSB Sep 1, 2010 10:54 AM (in response to MurraySummers)Thanks
Date: Wed, 1 Sep 2010 08:32:39 -0600
From: forums@adobe.com
Subject: Centering a Picture /Photo
Why is it absolutely positioned anyhow?
Why not this?
img {
width:520px;
height:335px;
margin:0 auto;
display:block;
}
</style>
</head>
<body>
</body>
>
-
5. Re: Centering a Picture /Photo
MurraySummers Sep 1, 2010 11:10 AM (in response to GESYMSB)You're welcome. Did it work for you?
-
6. Re: Centering a Picture /Photo
GESYMSB Sep 2, 2010 10:21 AM (in response to MurraySummers)Hey Pal, I had not try anything yet, I did save the complete page ( messages ) from adobe
as a pdf file to try it later, I got too many customers this last 2 days, so will have to wait.
If you thinking what I am doing for living, click here:
http://www.gondarelectronics.com
Date: Wed, 1 Sep 2010 12:10:37 -0600
From: forums@adobe.com
Subject: Centering a Picture /Photo
You're welcome. Did it work for you?
>
-
7. Re: Centering a Picture /Photo
MurraySummers Sep 2, 2010 10:35 AM (in response to GESYMSB)I recommend you hire a web developer to work on that site!
"Best View at 1024 X 768"?



