Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

Bleepbleepbleeping Computer Bleep Bleep


  • Please log in to reply
6 replies to this topic

#1 webrat

webrat

  • Members
  • 138 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:UK
  • Local time:12:34 PM

Posted 11 April 2008 - 10:41 AM

I'm sure there is a simple answer to this but I can't work it out. All I'm trying to do is fix the position/structure of the pages on my site when I change resolution on-screen.

My code is pretty tidy and I'm now using divs, ids or classes and an external stylesheet for almost every element following some pointers from the folks at Bleeping Computer, but no matter whether I use absolute or relative position, px, pt, or any other combo of values it all goes to pieces the second I change the screen settings. Is there a simple way around this or do I just build it and tell people to adjust their diplay (I really don't want to do this and am prepared to put the work in not to, but I'm a newb and running out of ideas)

Any pointers appreciated.

cheers

Jason

BC AdBot (Login to Remove)

 


#2 groovicus

groovicus

  • Security Colleague
  • 9,963 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Centerville, SD
  • Local time:05:34 AM

Posted 11 April 2008 - 11:31 AM

What happens when one changes resolution? If you wanted to, I suppose you could code a page for each resolution, but that would be a huge PITA, especially considering how many resolutions are possible (there are 13 possible on my system). Do you really want to code that many variations?

#3 webrat

webrat
  • Topic Starter

  • Members
  • 138 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:UK
  • Local time:12:34 PM

Posted 11 April 2008 - 12:03 PM

What happens is that everything becomes completely disorganised (images and hr's move relative to width etc etc) and it looks like a chimp has randomly placed objects on-screen.

I'm just concerned that if I don't do something the chances of anyone spending more than a second looking at it (assuming they don't have the same settings as I do) will be nill, making the whole enterprise a bit of a waste. There must be a way around it (unless I'm completely misunderstanding the way this works) as most sites you visit, even basic ones, render as you might expect when you visit them and don't assume a given resolution presumably.

#4 groovicus

groovicus

  • Security Colleague
  • 9,963 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Centerville, SD
  • Local time:05:34 AM

Posted 11 April 2008 - 12:55 PM

but no matter whether I use absolute or relative position, px, pt,


Have you tried using percentages? I don't know what to tell you. I always code my pages for 800x600 so I don't have to worry about scaling down. Maybe you want to rethink your layout?

#5 webrat

webrat
  • Topic Starter

  • Members
  • 138 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:UK
  • Local time:12:34 PM

Posted 11 April 2008 - 04:51 PM

Well, dont I feel like an idiot....

I took your advice and went through my code with a fine tooth-comb looking to rewrite it. Found a missing closure that had thrown the entire image positioning out of whack somehow. Lesson learned.

If in doubt, walk away and come back an hour later ready to concentrate.

Cheers

Jason

#6 pislkie

pislkie

  • Members
  • 17 posts
  • OFFLINE
  •  
  • Local time:12:34 PM

Posted 14 April 2008 - 06:54 PM

You could consider validating your code as you build a page at various stages. One way that many professional designers use is to preview in Firefox with a Validating plugin. I favour "HTML Validtaor" the one that incorporates HTML Tidy. This will highlight any code errors each time you preview a page as it progresses. I find it saves a massive amount of time and agravation.
>>>piskie<<<

#7 webrat

webrat
  • Topic Starter

  • Members
  • 138 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:UK
  • Local time:12:34 PM

Posted 15 April 2008 - 02:05 PM

Hey Pislkie,

Thanks for the pointers. I think....

Just ran my code past the w3 validator and it really didn't like it, despite the fact I'm coding from 2 reference manuals for HTML and CSS. Most common error was "omitted tag minimization parameter can be omitted only if OMITTAG NO is specified." which appear all over the place. I have no idea what that means, yet. Interestingly though, the Firefox error console only indicated 4 errors, which I was quite pleased about initially. Back to the drawing board.

Just for reference the above error is a DTD error! Thats why it's so common. Should be easy to fix if anyone else comes across it - Check your DTD and make sure it's done in full, including charset definition.

Edited by webrat, 15 April 2008 - 02:16 PM.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users