Solved

Tables not sitting correctly on one page of the site.

Posted on 2006-06-29
11
303 Views
Last Modified: 2013-11-24
On my site regarding where the tables are situated the tables are not sitting correctly.

With this page the tables are not alligned to the top of the page.

http://www.ota.com.au/catalogue/details.jsp?productID=144774&tier4=54480&tier3=30458&tier2=30993&tier1=30967&type=vendor

With this one they are

http://www.ota.com.au/catalogue/detailstest.jsp?productID=144774&details=more

The code is the same for both pages and when the brief or detailed description is click it switches to allow for more of less data, here is the code:

<%@ include file="/common/_staticHeader.jsp" %>

<%-- GET PRODUCT DETAILS --%>

<we:execute action="catalogue.detail" var="detail" type="parse">
    <we:param name="productID"><c:out value="${param.productID}" /></we:param>
    <we:param name="type"><c:out value="${param.type}" /></we:param>
    <we:param name="sendFinancePrice" value="1"/>
</we:execute>



<%-- page layout --%>

<t:insert template="/templates/page.jsp">



<x:choose>
      <x:when select="$detail//tier1">      </x:when>
      <x:otherwise>
            <c:redirect url="/common/error.jsp?prodnotfound=true" />
      </x:otherwise>
</x:choose>



<%-- ----------------------------------------------------------------------------------------------------------------- --%>
<x:set var="product" select="$detail//product" />
<c:set var="tier4Name"><x:out select="$detail//tier1/tier2/tier3/tier4/@name" /></c:set>
<c:set var="tier3Name"><x:out select="$detail//tier1/tier2/tier3/@name" /></c:set>

<%-- meta --%>
<t:set name="DCdate" direct="true">2004-12-07</t:set><%-- update dc date everytime page update --%>
<t:set name="title" direct="true"><x:out select="$product/@productName" /></t:set>

<t:set name="subSection" direct="true">
            <x:out select="$detail//tier1/@name" />
            - <x:out select="$detail//tier1/tier2/@name" />
        <c:if test="${tier3Name ne tier4Name}">
            - <x:out select="$detail//tier1/tier2/tier3/@name" />
        </c:if>
        - <x:out select="$detail//tier1/tier2/tier3/tier4/@name" />
            - <x:out select="$product/@productName" /></t:set>

<t:set name="description_abstract" direct="true">Products - <x:out select="$product/@productName" /></t:set>
<t:set name="keywords" direct="true"><x:out select="$product/@productName" /></t:set>
<%-- ----------------------------------------------------------------------------------------------------------------- --%>


<t:set name="current_page" direct="true">catalogue</t:set>


<%-- content --%>
  <t:set name="main" direct="true">



    <%-- navigation trail --%>
    <table width="100%" border="0" cellspacing="0" cellpadding="0">
      <tr>
          <tr>
              <td width="4" height="19"><img src="images/crumbs_left.gif" width="4" height="19" /></td>
        <td background="images/crumbs_middle.gif"> <a class="bctl" href="/catalogue/index.jsp?type=<c:out value="${param.type}" />">
          <c:choose>
            <c:when test="${(param.type=='vendor')}">Brands</c:when>
            <c:otherwise>Products</c:otherwise>
          </c:choose></a><span class="bct">&nbsp;&nbsp;&gt;&nbsp;&nbsp;</span><%-- tier 2 navigation trail --%><c:url value="tier2.jsp" var="tier2CatURL">
            <c:param name="type" value="${param.type}" />
            <c:param name="tier1">
              <x:out select="$detail//tier1/@id" />
            </c:param>
          </c:url> <a class="bctl" href="<c:out value="${tier2CatURL}" />"> <x:out select="$detail//tier1/@name" /></a>
          <span class="bct">&nbsp;&nbsp;&gt;&nbsp;&nbsp;</span> <%-- tier 3 navigation trail --%> <c:url value="tier3.jsp" var="tier3CatURL">
            <c:param name="type" value="${param.type}" />
            <c:param name="tier1">
              <x:out select="$detail//tier1/@id" />
            </c:param>
            <c:param name="tier2">
              <x:out select="$detail//tier1/tier2/@id" />
            </c:param>
            <c:param name="tier3">
              <x:out select="$detail//tier1/tier2/tier3/@id" />
            </c:param>
          </c:url> <a class="bctl" href="<c:out value="${tier3CatURL}" />"> <x:out select="$detail//tier1/tier2/@name" /></a>
          <span class="bct">&nbsp;&nbsp;&gt;&nbsp;&nbsp;</span> <c:if test="${tier3Name ne tier4Name}">
            <%-- tier 4 navigation trail --%>
            <c:url value="tier4.jsp" var="tier4CatURL">
              <c:param name="type" value="${param.type}" />
              <c:param name="tier1">
                <x:out select="$detail//tier1/@id" />
              </c:param>
              <c:param name="tier2">
                <x:out select="$detail//tier1/tier2/@id" />
              </c:param>
              <c:param name="tier3">
                <x:out select="$detail//tier1/tier2/tier3/@id" />
              </c:param>
              <c:param name="tier4">
                <x:out select="$detail//tier1/tier2/tier3/tier4/@id" />
              </c:param>
            </c:url>
            <a class="bctl" href="<c:out value="${tier4CatURL}" />">
            <x:out select="$detail//tier1/tier2/tier3/@name" /></a>
            <span class="bct">&nbsp;&nbsp;&gt;&nbsp;&nbsp;</span> </c:if> <%-- product list navigation trail --%> <c:url value="list.jsp" var="listURL">
            <c:param name="type" value="${param.type}" />
            <c:param name="tier1">
              <x:out select="$detail//tier1/@id" />
            </c:param>
            <c:param name="tier2">
              <x:out select="$detail//tier1/tier2/@id" />
            </c:param>
            <c:param name="tier3">
              <x:out select="$detail//tier1/tier2/tier3/@id" />
            </c:param>
            <c:param name="tier4">
              <x:out select="$detail//tier1/tier2/tier3/tier4/@id" />
            </c:param>
          </c:url> <a class="bctl" href="<c:out value="${listURL}" />"> <x:out select="$detail//tier1/tier2/tier3/tier4/@name" /></td>
        <td width="4"><img src="images/crumbs_right.gif" width="4" height="19" /></td>
      </tr>
    </table>

  <%-- navigation trail End --%>
<table width="100%" border="0" cellspacing="2" cellpadding="0">
        <tr rowspan="1">
          <td width="430" valign="top">
          <td rowspan="5" valign="top"><table width="151" border="0" cellpadding="0" cellspacing="0" background="images/related_bg.gif">
            <tr>
              <td height="19" align="center" background="images/related_titlebg.gif" class="verdana10">Related Top Sellers </td>
            </tr>
            <tr>
              <td height="5"><img src="images/space.gif" width="30" height="5" /></td>
            </tr>
            <tr>
              <td height="15" bgcolor="#414141"><p align="center"><span class="arial9white">Alternative Products</p></td>
            </tr>
            <tr>
              <td><table width="100%" border="0" cellspacing="3" cellpadding="0">
                  <tr>
                    <td width="35" valign="top"><img src="../images/Promos/Right_side/tecra.jpg" width="34" height="33" /></td>
                    <td class="arial9black" style="font-size: 9px">Toshiba Sat Pro A100 Intel Cel M3601.4Ghz</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$921.68</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td><a href="http://www.ota.com.au/catalogue/details.jsp?productID=157355&amp;tier4=16875&amp;tier3=16870&amp;tier2=16949&amp;tier1=16944&amp;type=vendor"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
                  <tr>
                    <td valign="top"><img src="images/content_computer3.gif" width="30" height="30" /></td>
                    <td class="arial9black"><p style="font-size: 9px">PRESARIO SR1715AN   DESKTOP PC</p></td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$600</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td height="25" valign="top"><a href="http://www.ota.com.au/catalogue/details.jsp?productID=145793&amp;tier4=54585&amp;tier3=54582&amp;tier2=54581&amp;tier1=16068&amp;type=group"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
              </table></td>
            </tr>
            <tr>
              <td height="15" bgcolor="#414141"><div align="center"><span class="arial9white">iPods</div></td>
            </tr>
            <tr>
              <td><table width="100%" border="0" cellspacing="3" cellpadding="0">
                  <tr>
                    <td width="35" valign="top"><img src="../images/Promos/Right_side/ipod_nano.jpg" width="36" height="50" /></td>
                    <td class="arial9black" style="font-size: 9px">iPod (60GB) White</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$600.40</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td><a href="http://www.ota.com.au/catalogue/details.jsp?productID=43829&amp;tier1=null"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
                  <tr>
                    <td valign="top"><img src="../images/Promos/Right_side/docking.jpg" width="46" height="33" /></td>
                    <td class="arial9black"><p style="font-size: 9px">Apple iPod   Universal Dock</p></td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$62.74</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td height="25" valign="top"><a href="http://www.ota.com.au/catalogue/details.jsp?productID=43808&amp;tier1=null"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
              </table></td>
            </tr>
            <tr>
              <td height="15" bgcolor="#414141"><div align="center"><span class="arial9white">New Products</span></div></td>
            </tr>
            <tr>
              <td><table width="100%" border="0" cellspacing="3" cellpadding="0">
                  <tr>
                    <td width="35" valign="top"><img src="../images/Promos/Right_side/tom_tom.jpg" width="45" height="26" /></td>
                    <td class="arial9black" style="font-size: 9px">TOMTOM ONE + CARRY CASE BUNDLE</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$786.56</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td><a href="http://www.ota.com.au/catalogue/details.jsp?productID=22366&amp;tier4=52629&amp;tier3=52628&amp;tier2=52697&amp;tier1=52696&amp;type=vendor"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
                  <tr>
                    <td valign="top"><img src="../images/Promos/Right_side/lgtft.jpg" width="50" height="37" /></td>
                    <td class="arial9black"><p style="font-size: 9px">LG 17&quot; LCD 12MS   1280X1024@ 75hZ 0.265MM PIXEL PITCH SILVER</p></td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td class="arial11bold">$266.13</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td height="25" valign="top"><a href="http://www.ota.com.au/catalogue/details.jsp?productID=9033&amp;tier1=null"><img src="images/button_addtocart.gif" width="85" height="19" border="0" /></a></td>
                  </tr>
              </table></td>
            </tr>
            <tr>
              <td height="4"><img src="images/related_bottom.gif" width="151" height="4" /></td>
            </tr>
          </table></td>
        </tr>
        <tr valign="middle" rowspan="4">
          <td><table width="430" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="3"><img src="images/box_1.gif" width="3" height="3" /></td>
                <td colspan="2" background="images/box_2.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td width="3"><img src="images/box_3.gif" width="3" height="3" /></td>
              </tr>
              <%-- Here we will only set the product logo if it exists we can get the name
               but will need to add the directory of where found and add on the .jpg
              extension --%>
              <c:set var="prodVendor"><x:out select="$product/@vendor" /></c:set>
              <c:choose>
              <c:when test="${prodVendor !=''}">
                <tr halign="right">
                  <td background="images/box_4.gif"><img src="images/space.gif" width="1" height="1" /></td>
                  <td width="200"><div align="right"></div></td>
                  <td width="229"><div align="center">
                    <div align="center"><img src="images/logo/<c:out value='${prodVendor}'/>.gif" /></div></td>
                  <td background="images/box_6.gif"><img src="images/space.gif" width="1" height="1" /></td>
                </tr>
              </c:when>
              <c:otherwise>              </c:otherwise>
              </c:choose>
              <tr>
                <td background="images/box_4.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td colspan="2"><table width="100%" border="0" cellspacing="5" cellpadding="0">
                    <tr>
                      <td width="185" valign="top"><table width="185" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td width="185" height="180"><%-- check image exist--%>
<c:set var="imageFile"><we:config name="resource.dir" />\<x:out select="$product/@imageName" /></c:set>



<c:set var="isFile"><file:isFile source="${imageFile}" /></c:set>




<c:choose>
      <c:when test="${isFile=='true'}">

                  <c:set var="imgWidth"><x:out select="$product/@imageWidth" /></c:set>
                  <c:set var="imgHeight"><x:out select="$product/@imageHeight" /></c:set>

                  <%-- change the maxSize & 190 to suitable re-size for the content  --%>
                  <fmt:parseNumber var="maxSize" type="number" value="190" />
                  <c:if test="${imgWidth > maxSize}">
                    <c:set var="imgHeight" value="${(imgHeight*maxSize) / imgWidth}" />
                    <c:set var="imgWidth" value="${maxSize}" />
                  </c:if>

                  <a href="/resources/<x:out select='$product/@imageName'/>" target="_blank" onclick="popupWindow('/resources/<x:out select='$product/@imageName'/>','Enlarge',600,550); return false;">
                        <img src="/resources/<x:out select='$product/@imageName'/>"
                        width="<c:out value='${imgWidth}'/>"
                        height="<fmt:formatNumber pattern='#' type='number'><c:out value='${imgHeight}'/></fmt:formatNumber>"
                        border="0"
                        alt="<x:out select='$product/@productName'/>" />                  </a>      </c:when>

      <c:otherwise>
            <img src="/images/image_not_avaliable.gif" width="190" height="79" alt="image no available" />      </c:otherwise>
</c:choose></td>
                          </tr>
                          <tr>
                            <td align="center" valign="middle"><table width="172" height="33" border="0" cellpadding="0" cellspacing="0">
                                <tr>
                                  <td align="center" valign="middle" background="images/buttonbg_addtocart.gif"><form method="post" action="/basket/actions/add.jsp">
                                    <div align="center">Qty:
                                      <input class="textfield" type="text" name="quantity" value="1" id="lb_Qty" size="1" maxlength="3" onfocus="saveQuantity(this)" onkeyup="checkQuantity(this)" />
                                              <input type="hidden" name="id" value="<x:out select='$product/@id' />" />
                                              <input type="hidden" name="type" value="product" />
                                              <input type="hidden" name="quantity" size="1" value="1" />
                                              <input name="Add to basket" type="image" src="/catalogue/images/button_addtocart.gif" alt="Add to basket" align="middle" />
                                      </div>
                                  </form></td>
                                </tr>
                            </table></td>
                          </tr>
                      </table></td>
                      <td valign="middle"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                          <tr>
                            <td><table width="100%" border="0" cellspacing="0" cellpadding="0"><tr>
                                  <td width="171" height="25" valign="top"><c:set var="title"><t:get name="title" default="" /></c:set>
              <p align="left" class="special_title" style="font-size: 15px; color:#932A2E;"><c:out value="${title}" escapeXml="false" /></p></td>
                            </table></td>
                          </tr>
                          <tr>
                            <td><table width="224" border="0" cellspacing="1" cellpadding="0">
                                <tr>
                                  <td width="95" height="15" bgcolor="#414141"><span class="arial9white">MANUFACTURER</span></td>
                                  <td valign="top" bgcolor="#E1E0E0"><x:out select="$product/@vendor" /></td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#414141"><span class="arial9white">MODEL NUMBER</span> </td>
                                  <td valign="top" bgcolor="#E1E0E0"><x:out select="$product/@vendorPart" /></td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#414141"><span class="arial9white">PRODUCT CODE</span></td>
                                  <td valign="top" bgcolor="#E1E0E0"><x:out select="$product/@productCode" /></td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#414141"><span class="arial9white">UNITS AVAILABLE</span></td>
                                  <td valign="top" bgcolor="#E1E0E0"><c:set var="stock">
                                      <x:out select="$product/@stock" />
                                    </c:set>
                                      <c:choose>
                                        <c:when test="${ stock eq '0' or empty stock }">Please call</c:when>
                                        <c:otherwise>
                                          <x:out select="$product/@stock" />
                                        </c:otherwise>
                                      </c:choose>                                  </td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#414141"><span class="arial9white">USUALLY SHIPS </td>
                                  <td valign="top" bgcolor="#E1E0E0">Same Day <a href="../about/freight_charges.jsp" target="_blank" class="bctl1">(QRS) </a></td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#414141"><span class="arial9white">WEIGHT</span></td>
                                  <td valign="top" bgcolor="#E1E0E0"><x:out select="$product/@weight" />
                                    kg</td>
                                </tr>
                                <tr>
                                  <td bgcolor="#414141"><span class="arial9white">NOTES</span></td>
                                  <td bgcolor="#E1E0E0"><p><a href="http://www.technewsletter.com.au/mwsubscribe/index.php?what=subscribe" target="_blank" class="bctl1">For the latest specials click here for free newsletter.</a></p></td>
                                </tr>
                                <tr>
                                  <td bgcolor="#99393A"><img src="images/title_price.gif" width="95" height="31" /></td>
                             <td nowrap="nowrap" bgcolor="#414141"> <%-- price(s) --%>
                    <p align="center">
                    <span class="arial26bold" style="font-size:26px;">
                  <fmt:formatNumber type="currency">
                    <x:out select="$product/@priceInc" />
                  </fmt:formatNumber>
                  <span class="price_ast"></span> </span>                          </p>


                          <p class="small"><b style="color:#666666;"></p>                      </td>
                                </tr>
                                <tr>
                                  <td height="15" bgcolor="#99393A"><span class="arial9white">LEASE/FINANCE</span></td>
                                  <td bgcolor="#414141"><span class="arial9white">
                                  <fmt:formatNumber type="currency"><x:out select="$product/@weeklyInc" /></fmt:formatNumber> /wk
                          </span></td>
                                </tr>
                            </table></td>
                          </tr>
                      </table></td>
                    </tr>
                </table></td>
                <td background="images/box_6.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <tr>
                <td><img src="images/box_7.gif" width="3" height="3" /></td>
                <td colspan="2" background="images/box_8.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td><img src="images/box_9.gif" width="3" height="3" /></td>
              </tr>
          </table></td>
        </tr>
        <c:set var="shortDesc"><x:out select="$product/@shortDescription" /></c:set>
        <%-- long description --%>
        <c:set var="longDesc"><x:out select="$product/@longDescription" /></c:set>
        <c:choose>
        <c:when test="${shortDesc !=''}">
        <%-- Begin Tab code --%>
        <tr valign="middle" rowspan="1">
          <td>
          <table border="0" cellpadding="0" cellspacing="0" bgcolor="">
              <tr>
                <c:choose>
                  <c:when test="${(param.details=='more')&&(longDesc !='')}">
                    <c:set var="descRowSpan" value="4" />
               
                    <td bgcolor="" >
                  </c:when>
                  <c:otherwise>
                    <c:set var="descRowSpan" value="1" />
                    <td>&nbsp;</td>
                    <td bgcolor="" >
                  </c:otherwise>
                </c:choose>
                &nbsp;&nbsp;<b><a class="fbox" style=";" href="detailstest.jsp?productID=<c:out value="${param.productID}" />">BRIEF DESCRIPTION</a></b>&nbsp;&nbsp;</td>
                <c:choose>
                        <c:when test="${longDesc ==''}">
                                <td>&nbsp;</td>
                        </c:when>
                        <c:when test="${(param.details=='more')&&(longDesc !='')}">
                                <td>&nbsp;</td>
                        </c:when>
                        <c:otherwise>
                                <td>&nbsp;</td>
                        </c:otherwise>
                </c:choose>
                <c:choose>
                        <c:when test="${(param.details=='more')&&(longDesc !='')}">
                                <td bgcolor="" >&nbsp;&nbsp;<b><a class="fbox" style="" href="detailstest.jsp?productID=<c:out value="${param.productID}" />&amp;details=more">DETAILED DESCRIPTION</a></b>&nbsp;&nbsp;</td>
                                <td>&nbsp;</td>
                        </c:when>
                        <c:when test="${(longDesc !='')}">
                                <td bgcolor="" >&nbsp;&nbsp;<b><a class="fbox" style="" href="detailstest.jsp?productID=<c:out value="${param.productID}" />&amp;details=more">DETAILED DESCRIPTION</a></b>&nbsp;&nbsp;</td>
                                <td>&nbsp;</td>
                        </c:when>
                        <c:otherwise>
                        </c:otherwise>
                </c:choose>
            </tr>
          </table>
          </td>
        </tr>
      <%-- End Tab code --%>
          <tr valign="top" rowspan=<c:out value="${descRowSpan}" />>
            <td><table width="430" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td width="3"><img src="images/box_1.gif" width="3" height="3" /></td>
                <td background="images/box_2.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td width="3"><img src="images/box_3.gif" width="3" height="3" /></td>
              </tr>
              <tr>
                <td background="images/box_4.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td height="8"><img src="images/space.gif" width="1" height="1" /></td>
                <td background="images/box_6.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <tr>
                <td background="images/box_4black.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td height="15" bgcolor="#414141" class="verdana10bold">MAIN FEATURES </td>
                <td background="images/box_6black.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <tr>
                <td background="images/box_4gray.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <c:choose>
                  <c:when test="${(param.details=='more')&&(longDesc !='')}">
                    <td valign="top" bordercolor="#F1F1F1" bgcolor="#F1F1F1">
                      <x:out select="$product/@longDescription" />
                    </td>
                  </c:when>
                  <c:when test="${(param.details!='more')&&(longDesc !='')}">
                    <td valign="top" bordercolor="#F1F1F1" bgcolor="#F1F1F1">
                      <x:out select="$product/@shortDescription" />
                    </td>
                  </c:when>
                  <c:otherwise>
                    <td valign="top" bordercolor="#F1F1F1" bgcolor="#F1F1F1">
                      <x:out select="$product/@shortDescription" />
                    </td>
                  </c:otherwise>
                </c:choose>
                <td background="images/box_6gray.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <%--
              <c:choose>
                <c:when test="${(longDesc !='') && (param.details!='more')}">
                <tr>
                  <td background="images/box_4gray.gif"><img src="images/space.gif" width="1" height="1" /></td>
                  <td valign="top" bordercolor="#F1F1F1" bgcolor="#F1F1F1">
                  <b>
                    <a class="fbox" style="color:#0000FF;" href="detailstest.jsp?productID=<c:out value="${param.productID}" />&amp;details=more">DETAILED DESCRIPTION</a>
                  </b>&nbsp;&nbsp;
                  </td>
                  <td background="images/box_6gray.gif"><img src="images/space.gif" width="1" height="1" /></td>
                </tr>
                </c:when>
                <c:otherwise>
                </c:otherwise>
              </c:choose>
              --%>
              <tr>
                <td background="images/box_4black.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td height="2" bgcolor="#414141"><img src="images/space.gif" width="1" height="1" /></td>
                <td background="images/box_6black.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <tr>
                <td background="images/box_4.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td>&nbsp;</td>
                <td background="images/box_6.gif"><img src="images/space.gif" width="1" height="1" /></td>
              </tr>
              <tr>
                <td><img src="images/box_7.gif" width="3" height="3" /></td>
                <td background="images/box_8.gif"><img src="images/space.gif" width="1" height="1" /></td>
                <td><img src="images/box_9.gif" width="3" height="3" /></td>
              </tr>
            </table></td>
          </tr>
        </c:when>
        <c:otherwise>
        </c:otherwise>
        </c:choose>
        <tr valign="top" rowspan="1">
          <td class="verdana10">Products are sold, for your safeguard, with a manufacturer's warranty. If you would like more information regarding this product including warranty details please visit the manufacturer's
            website or contact us at: <a href="mailto:sales@ota.com.au  ">sales@ota.com.au </a>call our hotline 1300 WE R OTA (937682).</td>
        </tr>
        <tr valign="top" rowspan="1">
          <td height="100"><table width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr>
              <td width="66%" align="left" valign="top"><a href="#"><img src="images/banner_emailus.jpg" width="211" height="72" border="0" /></a></td>
              <td width="34%" align="right" valign="top"><a href="#"></a><table cellpadding="0" cellspacing="0" border="0">
              <tr><td align="center"><table cellpadding="0" cellspacing="0" border="0"><tr><td align="center"><a href="http://srv0.velaro.com/visitor/requestchat.aspx?siteid=2824&showwhen=inqueue&deptid=1201" target="VelaroChat"  onClick="this.newWindow = window.open('https://srv0.velaro.com/visitor/requestchat.aspx?siteid=2824&showwhen=inqueue&deptid=1201', 'VelaroChat', 'toolbar=no,location=no,directories=no,menubar=no,status=no,scrollbars=no,resizable=yes,replace=no');this.newWindow.focus();this.newWindow.opener=window;return false;">
                <div align="center"><img alt="Velaro Live Help" src="https://srv0.velaro.com/visitor/check.aspx?siteid=2824&showwhen=inqueue&deptid=1201" border="0"></div></td>
              </tr></table></td>
              </tr>
            </table></td>
            </tr>
          </table></td>
        </tr>
        <tr valign="top" rowspan="2">
          <td height="40" colspan="2"><br />
            <%-- long description end --%>
            <br />
            <%-- ASSOCIATED PRODUCTS --%>
            <x:if select="$product/associated">
              <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td height="18" bgcolor="#922B2C" style="color:#ffffff;" align="center"><a name="ap" id="ap"></a><b>&nbsp;Associated products</b></td>
                </tr>
              </table>
              <table cellpadding="0" cellspacing="0" border="0" width="100%">
                <tr >
                  <td align="left" valign="top"><b>Code</b></td>
                  <td align="left" valign="top"><b>Vendor</b></td>
                  <td align="left" valign="top"><b>Item title</b></td>
                  <td align="right" valign="top" nowrap="nowrap"><b>Price<span class="price_ast">*</span></b></td>
                </tr>
                <x:forEach var="product" select="$product/associated">
                  <tr align="left" valign="top">
                    <td  class="list"><x:out select="$product/@productCode" /></td>
                    <td class="list"><x:out select="$product/@vendor" /></td>
                    <td class="list"><a class="fbox" href="/catalogue/detailstest.jsp?productID=&lt;x:out select='$product/@id'/&gt;&amp;tier1=null">
                      <x:out select="$product/@productName" />
                      </a>
                        <c:set var="image">
                          <x:out select="$product/@hasImage" />
                        </c:set>
                        <c:if test="${image eq 'true'}"> <img src="/images/camera_blue.gif" width="11" height="9" alt="camera icon" border="0" /></c:if>                    </td>
                    <td align="right" nowrap="nowrap"  class="list"><span class="price">
                      <fmt:formatNumber type="currency">
                        <x:out select="$product/@priceInc" />
                      </fmt:formatNumber>
                    </span></td>
                  </tr>
                </x:forEach>
              </table>
              <table width="100%" border="0" cellspacing="0" cellpadding="0">
                <tr>
                  <td height="1" bgcolor="#CCCCCC"><img src="/images/c.gif" width="1" height="1" alt="" /></td>
                </tr>
                <tr>
                  <td>&nbsp;</td>
                </tr>
              </table>
          </x:if></td>
        </tr>
      </table>
    <p>
      <jsp:include page="/includes/content_notes.jsp" />
  </t:set>
  </t:insert>
0
Comment
Question by:Adamylo
  • 5
  • 4
11 Comments
 
LVL 15

Expert Comment

by:bpmurray
Comment Utility
It's difficult to work out what you're using here - is it JSF?
0
 

Author Comment

by:Adamylo
Comment Utility
.jsp
0
 
LVL 15

Expert Comment

by:bpmurray
Comment Utility
No - I meant the framework and tags. You have <t:set>, <c:set> amd <x:set> - I presume at least one of these is JSTL, and you have constructs like value="${x.y}" which looks like Variable Bindings from JSF. In other words, you've left out the critical first few lines of the jsp.
0
 

Author Comment

by:Adamylo
Comment Utility
I copied the whole code from the page. I am not sure what you mean regarding JSTL I have some but limited code knowledge.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 
LVL 15

Expert Comment

by:bpmurray
Comment Utility
Didn't the page have <html><head> <@page .... etc?
0
 

Author Comment

by:Adamylo
Comment Utility
Thanks for your help so far.

The page does reference to <%@ include file="/common/_staticHeader.jsp" %> on top of the page.

The _staticheader.jsp looks like this.

<%@ include file="/common/_docType.jsp" %>
<%-- docType include above must remain on first line --%>

<%-- set error page --%>
<%@ page errorPage="/common/error.jsp" %>

<%-- standard tag libraries --%>
<%@ taglib uri="/WEB-INF/tld/x.tld" prefix="x" %>
<%@ taglib uri="/WEB-INF/tld/fmt.tld" prefix="fmt" %>
<%@ taglib uri="/WEB-INF/tld/fn.tld" prefix="fn" %>

<%-- isell tag libraries --%>
<%@ taglib uri="/WEB-INF/tld/we.tld" prefix="we" %>
<%@ taglib uri="/WEB-INF/tld/template.tld" prefix="t" %>
<%@ taglib uri="/WEB-INF/tld/email.tld" prefix="e" %>
<%@ taglib uri="/WEB-INF/tld/file.tld" prefix="file" %>

<c:set var="currentPage"><%=request.getServletPath()%></c:set>

<%-- set locale --%>
<fmt:setLocale value="en_AU" scope="application" />

<%-- date / time --%>
<jsp:useBean id="now" class="java.util.Date" />

<%-- set customer info if logged in--%>
<c:if test="${empty customer}">
  <we:execute action="customer.detail" var="customerXML" type="parse" />
  <x:set var="customer" select="$customerXML/response/customer" scope="request" />
  <x:if select="$customer">
    <c:set var="loggedIn" value="true" scope="request" />
  </x:if>
</c:if>
0
 
LVL 15

Expert Comment

by:bpmurray
Comment Utility
It's really difficult to say exactly what the problem is because there are so many tags. However, it looks like the reason it's not aligning on top is because this is table embedded in a table, and the row in which it's embedded has valign="middle" set. This means that if this item isn't tall enough to fill the space, it'll look as though it's sitting in the middle (as it does).

Anyway, the reason the thing doesn't fit to the same size is that the text on the right-hand side is in <td> tags that are smaller. I can't see the stylesheet for the page - are they identical? My guess is that they have different versions of the stylesheet, causing different padding sizes for the tables.
0
 

Author Comment

by:Adamylo
Comment Utility
So its in the CSS?
0
 
LVL 15

Accepted Solution

by:
bpmurray earned 500 total points
Comment Utility
There are two reasons for the difference. The first is that the size of the "Main Features" box is much bigger in the  page that displays correctly, so it pushes the table that's centrally-aligned up. As well as that, if you look at the "Notes" box, the space around the text is bigger in the page that displays OK. The markup is identical for both pages, and they have a style class of "bctl1". My guess is that each page has a different version of the stylesheet - look at screen.css and styles.css.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now