dcsimg
A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: -sorry to ask this DW question here..but I need..

  1. #1

    Lightbulb

    a little help. I'm trying to learn the basics of building a homepage - and I'm begining to bang my head against the wall. I want to make a page with should be seen in different resolution like 1024, 1280 and 1600... I work in 1600X1200 and I get some problems when splitting the page into frames - in preview in lower resolutions the proportions does not show up right and sometimes I'm only able to see on of the frames... The table I can set to like witdh 70% and that works well - unlees it's in a frame I can't see, dooh!! If I place a picture in a table this won't scale automatic with the changing resolution - it still keeps it size and proportions - how do get rid of this problem?....I have thought of starting designing a page in 1024X768 and then if a user have a bigger resolution it just gets smaller - is this the way to do it?
    If I work in 1600X1200 and set the window size to lets say 1024X768 maximized - will this work????
    Please if u have any cool ideas to get started I would be very glad - I prefer if the help could be refering to Dreamweaver - cause I'm not into clean html, eventhough I know that's important...
    Please any info would be appriciated - and again sorry for posting in this Flash forum, but U guys have helped me alot with Flash - so therefore....

    RegardZ ThomaZ

  2. #2
    Junior Member
    Join Date
    Jun 2000
    Posts
    18
    Hi!

    I'd suggest you create the page for the "low" (lol) resolution of 1024x768 and if anybody's using a higher setting, well, everything will be a little smaller, but you can always pass that off as a design statement.

    The other alternative (and it's a bit of a pain, though) is to create pages specifically for each resolution and use a Javascript re-direct page to check the visitor's res and send them to an appropriate page. (There's loads of simple scripts to do this at the regular Javascript sites, but I could give you a copy of it if you need it - we're talking about 10 lines of code, so I could just post it here)

    BTW, I personally NEVER use the preview option - it's much easier to create your page, save it, then open it in your browser. Check it then minimize it. Then, when you make a change to the page in DW, simply save it, minimize DW and hit refresh on your browser.

    Cheers,

    Kev

  3. #3
    thx KevS!

    - hhmm I've heard about that Java script before, but as u said it's a bit boring to make like three versions - but maybe that's the price to pay if u want a "picture perfect" designed page....

    - sorry for saying low resolution - but the people my site will have an interest for normaly use 1024 and above, I know 800X600 is the most common - but that I have no problem with...but then I could send those people to "low res low bandwidth place"

    - about the refresh stuff - I normaly have both my monitors turned on with my Matrox G400 DH, and that's easy too - DW on no.1 and IE on no.2 - just hate to restart my computer every time I wan't to play a game

    - so if I choose the check for resolution script how is this done? Is it possible to make a little flashfile saying in a cool way "checking resolution settings" or something and after that propt for the right site? I would appriciate if u could post the code

    - thx angain ThomaZ

  4. #4
    Junior Member
    Join Date
    Jun 2000
    Posts
    18
    Hi Thomaz,

    Okay - the script works in a pretty simple way (it's not very elegant, but it works).

    The easiest way to do this is to have your index.htm as a "splash-page" (okay, some people like 'em, some don't. I personally do). Ensure this page is pretty simple and can be viewed by any resolution.

    Now, create a page called "redirect.htm" and insert the Javascript below (it should go between the "HEAD" tags).

    On your index page, have a link saying "enter site" or similar (obviously, you could use a graphic or other "link" element). Link this to "redirect.htm"

    The visitor will click the link and be taken to the re-direction screen. One slight problem is that this can happen pretty quickly, so it may be worth leaving this page as featureless as possible.

    The Javascript will then take the visitor to the appropriate page.

    Note, this script supports 3 different settings, but it's pretty easy to add more or change the resolutions supported once you see how it works.

    I'd also suggest that on the "unsupported.htm" page (where users with low resolutions are sent) that you add manual links to the different pages (in this case "normal.htm" and "low.htm") Some users may have some weird screen res that you can't cater for, so it's nice to let them have the option.


    Hope this helps,

    Kev

    -------------

    <SCRIPT>
    var width=null;
    var height=null;
    //Just change the name of the .htm file below
    //for which you want your user to be directed to:
    // 1.htm is for 1024 users
    var location1= "norm.htm"
    // 2.htm is for 800 users
    var location2= "low.htm"
    // 3.htm is for 640 users
    var location3 = "unsupported.htm"
    //These functions get the screen resolution:
    width = screen.width;
    height = screen.height;
    //Send the browser to location 1:
    if(screen.width == "1152"){
    window.location.href = location1;}

    //Send the browser to location 1:
    if(screen.width == "1024"){
    window.location.href = location1;}

    //Send the browser to location 2:
    if(screen.width == "800"){
    window.location.href = location2;}

    //Send the browser to location 3:
    if(screen.width == "640"){
    window.location.href =location3;}
    </SCRIPT>

  5. #5
    Thx again....

    - ok the script seems preety foreward, but I have a couple of questions....

    1) Should the quotation marks "" be there or not?

    2) The 1152 option is that a number of all resolutions above 1024 - or is just another resolution?

    - looking foreward to ur reply

  6. #6
    Junior Member
    Join Date
    Jun 2000
    Posts
    18
    Hi Thomaz,

    I have " marks in the code and it works okay!

    As for the 1152/1024 issue - I was redirecting both sets of users to the same place simply because I was too lazy to produce a 1152 page! (That's why the almost identical lines appear refering to 1152 and 1024 "send to browser location 1").

    This is the only problem with this script - you have to be specific about EVERY resolution you wish to support.

    Anyway, I hope this helps,

    Cheers,

    Kev

  7. #7
    hhhmmm...what will happen if a person with a wierd resolution enter - and his resolution isn't supported? - like that 1152 (not one I've heard about - mac stuff?)

    thx ThomaZ

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center