Wrox Programmer Forums
|
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Dreamweaver (all versions) section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 4th, 2005, 06:55 PM
Registered User
 
Join Date: Jan 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default more problems

It isn't easy, this web building lark! I'm still on chapter 2 -ive defined the first table & entered the the 2 .gif files as per the book. The problem is that the images in the two cells only align if the browser window is maximised- is there any way I can get the page to disply properly in a smaller browser window?

 
Old January 5th, 2005, 03:48 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Can you post the code for the table you're having problems with??

Cheers,


Imar
 
Old January 5th, 2005, 06:22 AM
Registered User
 
Join Date: Jan 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

this is the code for the entire site up to about half way through chapter 3:

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>The Cooking Place-Home Page</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
</head>

<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="MM_preloadImages('Images/news_over.gif','Images/regions_over.gif','Images/contact_over.gif')">
<table width="100%" border="0" cellpadding="0" cellspacing="0" background="Images/topbkg.gif">
  <tr>
    <td width="50%"><img src="Images/topleft.gif" width="290" height="51" /></td>
    <td width="50%"><strong>The
      Cooking Place</strong></td>
  </tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td width="257" valign="top" background="Images/sidebkg.gif"><table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td><img src="Images/topleft2.gif" width="257" height="112" /></td>
        </tr>
      </table>
      <table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="50%" valign="top" background="Images/rightsidebkg.gif"><img src="Images/topleft3.gif" width="195" height="75" /><br />
            <img src="Images/home_over.gif" width="181" height="31" /><br />
            <a href="news.htm" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('newsButton','','Images/news_over.gif',1)"><img src="Images/buttonblank.gif" alt="News" name="newsButton" width="181" height="31" border="0" id="newsButton" /></a>
            <br />
            <a href="regions.htm" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('regionsButton','','Imag es/regions_over.gif',1)"><img src="Images/buttonblank.gif" alt="Regions" name="regionsButton" width="181" height="31" border="0" id="regionsButton" /></a>
            <br />
            <a href="mailto:charles@thecookingplace.com" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage('contactButton','','Imag es/contact_over.gif',1)"><img src="Images/buttonblank.gif" alt="Contact Us" name="contactButton" width="181" height="31" border="0" id="contactButton" /></a>
          </td>
          <td width="50%" valign="top"><img src="Images/page.gif" width="59" height="199" /></td>
        </tr>
      </table></td>
    <td width="99%" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td width="1%" valign="top"><img src="Images/leftcorn.gif" width="28" height="22" /></td>
          <td width="98%">&nbsp;</td>
          <td width="1%" align="right" valign="top"><img src="Images/rightcorn.gif" width="28" height="22" /></td>
        </tr>
      </table>
    </td>
    <td width="1%" background="Images/rightsidebkg.gif"><img src="Images/rightsidebkg.gif" width="24" height="31" /></td>
  </tr>
</table>
<table width="100%" border="0" cellpadding="0" cellspacing="0" background="Images/botbkg.gif">
  <tr>
    <td width="50%"><img src="Images/botleft.gif" width="235" height="40" /></td>
    <td width="50%" align="right"><img src="Images/botright.gif" width="69" height="40" /></td>
  </tr>
</table>
</body>
</html>

I still have the same problem with images not aligning properly in an non-maximised browser window, and the page doesnt fill up the entire height of the window-there is white space at the bottom

 
Old January 5th, 2005, 06:36 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Andy,

I am not sure I understand the problem. I used your code tother with the images from the book, and everything looks fine to me. What browser do you view this in? And more importantly: what resolution do you view this in??

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: Hell Is Round The Corner by Tricky (Track 4 from the album: Maxinquaye) What's This?
 
Old January 6th, 2005, 06:08 AM
Registered User
 
Join Date: Jan 2005
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Imar
     Thanks for all the help so far, I probably would have given up otherwise! The site works fine in 800 X 600 reasolution, but not anything higher. Even at 800 X 600, you still get problems with image alignment if the browser window is shrunk below a certain size-is there any way of fixing this?

I'm using IE (the latest version!)

 
Old January 6th, 2005, 04:22 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi again,

It doesn't display correct on anything higher than 800? I'd expected it to work on higher resolutions rather than on lower. I viewed your code on a 1280 screen, and only when I decreased the browser size to 500 or so, things fell apart. The site is designed to look good on screens with a resolution of 800 and up.

This is what I am seeing on my 1280x1024 monitor with the window resized to just over 800 px. Isn't this what you're seeing??

http://Imar.Spaanjaars.Com/Demos/The...emoScreen1.jpg

Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: Sabotage by Beastie Boys (Track 6 from the album: Ill Communication) What's This?





Similar Threads
Thread Thread Starter Forum Replies Last Post
Problems already! KennySargent BOOK: Professional XNA Programming 2nd Edition ISBN: 978-0-470-26128-6 4 April 7th, 2008 03:36 AM
Have 2 problems so far... Soulcatcher BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 2 June 20th, 2007 12:57 PM
c problems saurabh1983in C++ Programming 6 November 29th, 2005 04:23 AM
validate.asp problems and logon.asp problems p2ptolu Classic ASP Databases 0 February 16th, 2005 02:34 PM
Problems kilika Javascript 1 October 3rd, 2003 02:42 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.