Thread: Web Pages Width Question
Results 1 to 6 of 6
-
25th Mar 2009, 4:39 PM #1
Web Pages Width Question
I'm just wondering a) how you set the width of a web page to like 900px so people with older monitors can see the page without the scrollbar at the bottom of the page and b) how do you set a web page so the images etc are displayed in generally the same width (e.g. If I were to create an image to go above one of the main paragraphs of my webpage, and it was designed to match the width of the border to the paragraph, how would I make sure that this stayed consistently in all browsers?)
Thanks.
-
25th Mar 2009, 5:43 PM #2
If you use tables you can set the width of each column to be a percentage of the screen - that way it will resize itself to fit on almost any screen. For example, my site has 15% for the left column, a 1% gap, 66% for the main window, another 1% gap and 15% for the right pane. If you resize your browser it will resize each of the columns.
If you're not using tables then text should automatically wrap to the size of the page (example). You can't (as far as I know) have the browser automatically resize an image - if you want it to be the same width as the text then you'll have to define the width of the text within a table and size the image accordingly - just under 800px if you want to be absolutely inclusive or just under 1024 if you want to include most users. Alternatively, if you can you make the image's background colour the same as the page's (or cell's) background colour and then centre align it - that way no one will know where the image ends and the background begins.
I'm sure there are more complicated and more straightforward answers out there but that's how I'd do it.Dennis, Francois, Melba and Smasher are competing to see who can wine and dine Lola Whitecastle and win the contract to write her memoirs. Can Dennis learn how to be charming? Can Francois concentrate on anything else when food is on the table? Will Smasher keep his temper under control?
If only the 28th century didn't keep popping up to get in Dennis's way...
#dammitbrent
The eleventh annual Brenty Four serial is another Planet Skaro exclusive. A new episode each day until Christmas in the Brenty Four-um.
-
26th Mar 2009, 6:29 AM #3
Thanks Lis... cos the only problem with My Family Online is that I just couldn't *get* columns to work at all, whatever I did it just looked naf, so in the end I settled for trying to get the web page content in the center with a good width of main content, the main content is defined within the CSS Style Code right at the top of the page.
I'm not the most experienced web designer in the world, but I would say I'm pretty good now compared to the point I was at least year (didn't even know what HTML stood for ) i.e... knowing nowt..
Here's a piece of coding from the main page (hope I'm OK to post this)
html { background: #909090 ; color:#000; font-family:"Helvetica", "Arial", "Bitstream Vera Sans", "Verdana", sans-serif; font-size:93.3%; margin:0; padding:0;}
body {background:#909090; color:000; font-family:"Trebuchet MS"; font-size: 94%; margin:50; padding: 0;}
-
26th Mar 2009, 3:20 PM #4
Lissa - you should really be using div tags and CSS rather than tables, but the principle's more or less the same.
We ride tornadoes. We eat tomatoes.
-
31st Mar 2009, 12:22 PM #5
One thing that's bugging me - Columns? I know the coding and everything but there's always something that goes wrong e.g. text increases, page goes all wierd etc.
-
27th May 2009, 6:15 PM #6
Probably just freewebs playing silly buggers... but surely if you specify <table width="800" align="center"> *that* will be the width of the body? Cos atm, I'm getting this thing where theres a massive white space and a small gray border, but the text seems to keep to the ' width="800" '...
... god I'm confused...Tom Simpson
My Top Three: "The War Games", "The Caves of Androzani" & "Time-Flight".
Similar Threads
-
Now with Extra Width
By Philipnet in forum Announcements and FeedbackReplies: 20Last Post: 6th Nov 2013, 1:51 PM -
Cached pages
By MinaHarker in forum Mr Smith, I Need You!Replies: 11Last Post: 5th Jul 2010, 6:48 AM
PSAudios 6.1. Bless You Doctor Who
[/URL] (Click for large version) Doctor Who A thrilling two-part adventure starring Brendan Jones & Paul Monk & Paul Monk Bless You,...
23rd Nov 2020, 3:02 PM