Forum Moderators: open

Message Too Old, No Replies

Bad display on different browsers

         

divz2

12:44 pm on Mar 23, 2007 (gmt 0)

10+ Year Member



I created a web site and uploaded it. It is working well on my computer but the problem is that it appears stretched on other computers and some pictures appear on wrong places. It is still working properly on my computer. Can anyone help me with this problem..Thanks in advance.

tedster

2:06 pm on Mar 23, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hello divz2, and welcome to the forums.

There are many reasons this happens and they are all something you can fix. It sounds mostly like a screen resolution problem, but in some cases which browser is in use can also cause those kinds of problems.

The first step you should take is validating your html mark-up with the W3C's online tool. It can be impossible trying to get different computers to render the same when there is invalid code.

W3C Validator - HTML [validator.w3.org]

But beyond that, note that somewhere in your mark-up, you are probably assuming that everyone's screen is the same resolution as yours. If the alignment of your page's elements depends on 100% being the same number of pixels for everyone, then anyone whose screen is wider or narrower than yours will see something wonky.

[edited by: tedster at 8:41 pm (utc) on Mar. 23, 2007]

divz2

3:17 pm on Mar 23, 2007 (gmt 0)

10+ Year Member



Hi, Thanks for your reply. I am working on the front page of this website. I did not change any resolutions of the page which was previously existing. I just added a flash file and few minor changes to the old page. The old page was working properly on all computers so why is this new page having problems when I did not change any resolutions? Thank you very much for your help.

simonuk

3:32 pm on Mar 23, 2007 (gmt 0)

10+ Year Member



Best thing to do is to test it yourself at various resolutions and see if anything changes.

It may also be that they had increased the font size or magnified the whole page which could also break it.

divz2

4:34 pm on Mar 23, 2007 (gmt 0)

10+ Year Member



Hi, Thanks a lot for all your replies. I tried changing the screen resolutions and seeing the web page. It works properly only in 1024 X 768pixels. It appears stretched in all other resolutions. How can I make the page work in all screens. Any help?

g1smd

9:04 pm on Mar 23, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



If you need it to be "pixel perfect" then you're going to have to set the page width to be a fixed amount.

divz2

10:08 am on Mar 26, 2007 (gmt 0)

10+ Year Member



Thank you very much for all your replies. I have been trying to change the table width to percentages from pixels. Can anyone tell me how can we change the pixels when there are no tables and "div" function is present? Thank you.

simonuk

10:29 am on Mar 26, 2007 (gmt 0)

10+ Year Member



As a quick fix you need a "container" div to hold everything in place.

Just below the <body> add:

<div id="container">

Just above </body> add </div>

Then in the css file create:

#container {width: 750px;}

If you want it centered on the page change it to:

#container {width: 750px;margin 0 auto;}

Adjust width to suit, it is only an example

divz2

10:45 am on Mar 26, 2007 (gmt 0)

10+ Year Member



Hi, I do have containers in my program I just want to know how can we adjust the size of it if we want the program to run in all screen resolutions.Thank you.

divz2

12:46 pm on Mar 26, 2007 (gmt 0)

10+ Year Member



Helloo...can anyone help me about this topic. I am trying to make my website work in all screen resolutions but it is not working...Please HELPPPP! thank you

simonuk

9:01 am on Mar 27, 2007 (gmt 0)

10+ Year Member



There is no magic fix for this. Without even the basic understanding of how it works you will struggle.

My fix above will work. You just need to paste it into the right place in the html without breaking the rest of the page. You change the 750px to whatever size you want it (100% will stretch, 740px will work on 800x600 and above etc etc).

If you don't understand how then you're going to need to pay a professional to do it for you or you need to start reading up :)

abhishekkaushik

1:51 am on Apr 13, 2007 (gmt 0)

10+ Year Member



This is happening because you have not designed you pages for all resolutions, in order to do so you must do the following.

(1)Give the body tag fixed pixel width like 800px and not 100%;

(2)In order to align the body of page at the middle of screen you need to put the following code attribute in the body tag

margin:0 auto;

(3)Next inside the body like (a)header div/table (b)main content div/table and (c)Footer div/table

give them 100% width this fill stretch the inside elements to body div but not outside it.