Important Notice from AspDotNetStorefront
It is with dismay that we report that we have been forced, through the action of hackers, to shut off write-access to this forum. We are keen to leave the wealth of material available to you for research. We have opened a new forum from which our community of users can seek help, support and advice from us and from each other. To post a new question to our community, please visit: http://forums.vortx.com
Results 1 to 4 of 4

Thread: xml package is too wide

  1. #1
    press is offline Member
    Join Date
    May 2009
    Posts
    31

    Default xml package is too wide

    Hi my product.variantsInDropDown.xml is too wide to fit my page and moves down under everything. I tried changing the #content and #wrapper css. Which would work if the rest of the page design could accommodate that. What a really need to do is to make the package narrower. I tried the width settings, but to no avail. Any ideas.

    Here is the code:

    <xsltherwise>
    <table border="0" width="100%" cellpadding="4" cellspacing="0">
    <tr>
    <td align="left" valign="top">
    <xsl:value-of select="aspdnsf:LookupProductImage(ProductID, ImageFilenameOverride, SKU, 'medium', 1, $AltText)" disable-output-escaping="yes"/>
    </td>
    <td align="left" valign="top" width="100%">
    <div>
    <table width="100%" cellpadding="0" cellspacing="0">
    <tr>
    <td width="100%" align="left" valign="middle">
    <span class="ProductNameText">
    <xsl:value-of select="$pName" disable-output-escaping="yes" />
    </span>
    <br/>
    </td>
    <td align="right" valign="Middle">
    <nobr>
    <xsl:value-of select="aspdnsf:ProductNavLinks(ProductID, /root/Runtime/EntityID, /root/Runtime/EntityName, /root/EntityHelpers/*[name()=/root/Runtime/EntityName]/descendant::Entity[EntityID=/root/Runtime/EntityID]/SEName, 0, 1, 1)" disable-output-escaping="yes" />
    <xsl:value-of select="aspdnsf:EmailProductToFriend(ProductID, $CatID)" disable-output-escaping="yes"/>
    </nobr>
    </td>
    </tr>
    </table>
    </div>
    <div>
    </div>
    <div>
    <xsl:value-of select="$pDescription" disable-output-escaping="yes"/>
    <br/>
    <br/>
    </div>
    <div>
    </div>
    <div>
    Options: <select name="variants" onchange="SetCartVariant(this.value)">
    <xsl:apply-templates select="/root/ProductVariants/Variant" />
    </select>
    <xsl:if test="aspdnsf:AppConfigBool('DisplayOutOfStockProd ucts') = 'true'">
    <xsl:value-of select="aspdnsfisplayProductStockHint(ProductID, VariantID, 'Product')" disable-output-escaping="yes" />
    </xsl:if>
    <div>
    <br/>
    </div>
    <xsl:value-of select="aspdnsf:AddtoCartForm(ProductID, $defaultVariant, 1)" disable-output-escaping="yes"/>
    </div>
    </td>
    </tr>
    </table>
    <xsl:value-of select="aspdnsf:RelatedProducts(ProductID)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:RecentlyViewed(ProductID)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:ShowUpsellProducts(ProductID)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:AlsoBought(ProductID, VariantID)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:ProductSpecs(ProductID, 1)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:ProductRatings(ProductID, 0, 0, 0, 1)" disable-output-escaping="yes"/>
    <xsl:value-of select="aspdnsf:Topic('imagepricetable')" disable-output-escaping="yes" />
    </xsltherwise>

    Thanks.

  2. #2
    BFG 9000 is offline Senior Member
    Join Date
    Oct 2006
    Location
    South UK
    Posts
    882

    Default

    It's impossible to say for sure without seeing it in your template - can you give us a link?


    TTFN

    BFG

  3. #3
    press is offline Member
    Join Date
    May 2009
    Posts
    31

    Default

    Here are two links.

    Based on the content, you can see how the bottom one causes the whole section to be too large.

    http://aspdotnetstorefront.spectrump...ark-white.aspx

    http://aspdotnetstorefront.spectrump...rtec-subs.aspx

  4. #4
    BFG 9000 is offline Senior Member
    Join Date
    Oct 2006
    Location
    South UK
    Posts
    882

    Default

    OK - I see the problem - try this...


    Replace this bit :-

    C#/VB.NET Code:
    <div>
    <
    br/>
    </
    div>
    <
    xsl:value-of select="aspdnsf:AddtoCartForm(ProductID, $defaultVariant, 1)" disable-output-escaping="yes"/>
    </
    div>
    </
    td>
    </
    tr
    </
    table

    With this :-


    C#/VB.NET Code:
    <div>
    <
    br/>
    </
    div>
    </
    div>
    </
    td>
    </
    tr
    <
    tr>
    <
    td colspan="2">
    <
    xsl:value-of select="aspdnsf:AddtoCartForm(ProductID, $defaultVariant, 1)" disable-output-escaping="yes"/>
    </
    td>
    </
    tr>
    </
    table


    That's just a very quick change to give you the principal.
    We're basically just moving the add to cart form into its own row.

    Bear in mind though that if you had an even longer variant name - you'd hit the problem again.


    TTFN

    BFG