Spry Accordian - Updating a Site

Ask a Question related to Macromedia Exchange Dreamweaver Extensions, Design and Development.

  1. #1

    Default Spry Accordian - Updating a Site

    Hi all,

    I have a site in development that uses Spry accordian. It displays great in
    Firefox but in IE the accordian menu will not collapse. I am told I need to
    upgrade to the latest accordion, but I didn't develop that portion of the site
    so have no clue how to fix it.

    Here's the site: [url]http://www.customizemydesigns.com[/url] - it's still in testing and
    I am still building the API scripts for the fulfillment company - see how in
    Firefox it looks great - but in IE it's not collapsing. Since I didn't develop
    the code in the page, how do I update it? Is it a matter of replacing the
    spryaccordion.js? There's some other code mixed in, but here's the block. So,
    how can I upgrade (if that will fix the issue) - or how can it be fixed:



    <div id="Accordion1" class="Accordion" tabindex="0">
    {section name=ii
    loop=$pro_arr}
    <div
    class="AccordionPanel">
    <div
    class="AccordionPanelTab"><span>{$pro_arr[ii].name}</span></div>

    <div
    class="AccordionPanelContent">
    {section
    name=jj loop=$prosub_arr[ii]}
    <li><a
    class="subcat"
    href="?pr=create_design&procat_id={$prosub_arr[ii][jj].id}">{$prosub_arr[ii][jj]
    ..name}</a></li>
    {/section}
    </div>

    </div>

    {/section}

    steve@steve-shead.co Guest

  2. Similar Questions and Discussions

    1. Updating Updating site map or archive dynamically
      Hi there! ;-) Posted in Site Design as well.... Anyone know if there is a way to use Contribute to automatically/dynamically update a site map...
    2. Close Spry Accordian panel without opening another
      I'd like my page to load with all Spry Accordian panels closed. Is there a way to just close a panel without opening another one?
    3. Spry Accordian IE issue
      :mad; Here is my test page: http://bankdemo.goldleaf.com/wa/2095_DEV/accordian-test.htm Firefox all is fine. However when using IE6 to test...
    4. Updating site with contribute
      Can you easily update a tableless designed site? A customer of mine wants to update/replace photos and text on a regular basis. Thank you.
    5. updating whole site
      H P T wrote: If its the same paragraph in every file... for instance a change of address or phone... use a find and replace utility. ...
  3. #2

    Default Re: Spry Accordian - Updating a Site

    [email]steve@steve-shead.co[/email] wrote:
    > Hi all,
    >
    > I have a site in development that uses Spry accordian. It displays great in
    > Firefox but in IE the accordian menu will not collapse. I am told I need to
    > upgrade to the latest accordion, but I didn't develop that portion of the site
    > so have no clue how to fix it.
    You can download the latest Spry code form the Spry home page:
    [url]http://labs.adobe.com/technologies/spry/home.html[/url]
    Go into the widgets/accordion directory and copy the SpryAccordion.js and SpryAccordion.css files into the appropriate location within your site, that is your js and css directories respectively.

    Also, Spry questions should be asked in the Spry forum:
    [url]http://www.adobe.com/cfusion/webforums/forum/categories.cfm?forumid=72&catid=602[/url]

    Also, I've heard that IE can be persnickety with JavaScript widgets when the page is being rendered in quirks mode, which it uses when it runs into when the HTML it runs into on a page isn't valid according to the specified doctype. A quick validation of your page yields a number of HTML errors, and it's possible that some of them may cause IE some problems with scripting:
    [url]http://validator.w3.org/check?verbose=1&uri=http%3A%2F%2Fwww.customizemyde signs.com%2F[/url]

    This page shows a technique to determine if IE is using quirks mode:
    [url]http://randsco.com/index.php/2007/03/12/about_quirks_mode[/url]



    --
    Danilo Celic
    | [url]http://blog.extensioneering.com/[/url]
    | WebAssist Extensioneer
    | Adobe Community Expert
    danilocelic AdobeCommunityExpert Guest

  4. #3

    Default Re: Spry Accordian - Updating a Site

    Danilo,

    Firstly, thanks for the prompt reply and the detailed answer. I downloaded the
    latest Spry and replaced the JS and the CSS as stated. That fixed the
    collapsing issue but destroyed the page style, so I put my CSS back in and it
    works a treat.

    Sorry about the wrong forum - I didn't dig deep enough.

    There are quirks to the page code and the page is rendering in quirk mode, but
    for now it's stable. Once the development on the designer code and API are done
    I'll go back and clean up the pages. It needs to be done anyway.

    Again, thanks for your help!

    Steve

    steve@steve-shead.co Guest

  5. #4

    Question Re: Spry Accordian - collasping problem

    Hello Steve. I am also using an accordion on my site, ans also took the advice to update to the latest spry, which didn't seem to make a lot of difference to be honest (I am using DW CS3)

    But the problem I am having is when you first come to the page the menu isn't completely collapsed and I wonder if there is a way of doing this...

    see the code below. Any help would be greatly appreciated. Thanks

    <!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>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>
    <script src="SpryAssets/SpryAccordion.js" type="text/javascript"></script>
    <link href="SpryAssets/SpryAccordion.css" rel="stylesheet" type="text/css" />
    </head>

    <body>
    <div id="Accordion1" class="Accordion" tabindex="0">
    <div class="AccordionPanel">
    <div class="AccordionPanelTop" onclick="Accordion1.openPanel(0); return false;">memory cards (make)</div>
    <div class="AccordionPanelContent">
    <img src="images/new/trans.gif" width="7" height="7" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="12" /><br />micro SD / Transflash<br />
    <img src="images/new/trans.gif" width="7" height="3" />
    </div>

    </div>
    <div class="AccordionPanel">
    <div class="AccordionPanelTab" onclick="Accordion1.openPanel(1); return false;">memory cards (brand)</div>
    <div class="AccordionPanelContent2">Content 2</div>
    </div>
    <div class="AccordionPanel">
    <div class="AccordionPanelTab" onclick="Accordion1.openPanel(2); return false;">mobile accessories</div>
    <div class="AccordionPanelContent">Content 2</div>
    </div>
    <div class="AccordionPanel">
    <div class="AccordionPanelTab" onclick="Accordion1.openPanel(3); return false;">gaming</div>
    <div class="AccordionPanelContent">Content 2</div>
    </div>
    <div class="AccordionPanel">
    <div class="AccordionPanelTab" onclick="Accordion1.openPanel(4); return false;">computing</div>
    <div class="AccordionPanelContent">Content 2</div>
    </div>
    <div class="AccordionPanel">
    <div class="AccordionPanelBot" onclick="Accordion1.openPanel(5); return false;">customer login</div>
    <div class="AccordionPanelContent">Content 2</div>
    </div>
    </div>
    <script type="text/javascript">
    <!--
    //var Accordion1 = new Spry.Widget.Accordion("Accordion1", {closedClass:"Accordion"});
    //var Accordion1 = new Spry.Widget.Accordion("Accordion1", {closedClass:"AccordionPanel"});
    var Accordion1 = new Spry.Widget.Accordion("Accordion1", { useFixedPanelHeights: false });
    //-->
    </script>
    </body>
    </html>


    css

    @charset "UTF-8";

    /* SpryAccordion.css - Revision: Spry Preview Release 1.4 */

    /* Copyright (c) 2006. Adobe Systems Incorporated. All rights reserved. */

    /* This is the selector for the main Accordion container. For our default style,
    * we draw borders on the left, right, and bottom. The top border of the Accordion
    * will be rendered by the first AccordionPanelTab which never moves.
    *
    * If you want to constrain the width of the Accordion widget, set a width on
    * the Accordion container. By default, our accordion expands horizontally to fill
    * up available space.
    *
    * The name of the class ("Accordion") used in this selector is not necessary
    * to make the widget function. You can use any class name you want to style the
    * Accordion container.
    */
    .Accordion {
    width: 174px;

    overflow: hidden;
    }

    /* This is the selector for the AccordionPanel container which houses the
    * panel tab and a panel content area. It doesn't render visually, but we
    * make sure that it has zero margin and padding.
    *
    * The name of the class ("AccordionPanel") used in this selector is not necessary
    * to make the widget function. You can use any class name you want to style an
    * accordion panel container.
    */
    .AccordionPanel {
    margin: 0px;
    padding: 0px;
    }

    /* This is the selector for the AccordionPanelTab. This container houses
    * the title for the panel. This is also the container that the user clicks
    * on to open a specific panel.
    *
    * The name of the class ("AccordionPanelTab") used in this selector is not necessary
    * to make the widget function. You can use any class name you want to style an
    * accordion panel tab container.
    */
    .AccordionPanelTab {
    background-color: #CCCCCC;
    letter-spacing: -0.04em;
    background-image: url(../images/new/spry/meun_blue.gif);
    background-repeat: no-repeat;
    padding: 8px 0 0 12px;
    height: 21px;
    font-family: Arial, Helvetica, sans-serif;
    color:#666666;
    font-size: 14px;
    font-weight: bold;
    margin: 0px;
    cursor: pointer;
    -moz-user-select: none;
    -khtml-user-select: none;
    }
    .AccordionPanelTop {
    background-color: #CCCCCC;
    letter-spacing: -0.04em;
    background-image: url(../images/new/spry/meun_top.gif);
    background-repeat: no-repeat;
    padding: 8px 0 0 12px;
    height: 22px;
    font-family: Arial, Helvetica, sans-serif;
    color:#666666;
    font-size: 14px;
    font-weight: bold;
    margin: 0px;
    cursor: pointer;
    -moz-user-select: none;
    -khtml-user-select: none;
    }
    .AccordionPanelBot {
    background-color: #CCCCCC;
    letter-spacing: -0.04em;
    background-image: url(../images/new/spry/meun_bot.gif);
    background-repeat: no-repeat;
    padding: 8px 0 0 12px;
    height: 21px;
    font-family: Arial, Helvetica, sans-serif;
    color:#666666;
    font-size: 14px;
    font-weight: bold;
    margin: 0px;
    cursor: pointer;
    -moz-user-select: none;
    -khtml-user-select: none;
    }

    /* This is the selector for a Panel's Content area. It's important to note that
    * you should never put any padding on the panel's content area if you plan to
    * use the Accordions panel animations. Placing a non-zero padding on the content
    * area can cause the accordion to abruptly grow in height while the panels animate.
    *
    * Anyone who styles an Accordion *MUST* specify a height on the Accordion Panel
    * Content container.
    *
    * The name of the class ("AccordionPanelContent") used in this selector is not necessary
    * to make the widget function. You can use any class name you want to style an
    * accordion panel content container.
    */
    .AccordionPanelContent {
    letter-spacing: -0.05em;
    background-image: url(../images/new/spry/meun_grey.gif);
    background-repeat: repeat-y;
    padding: 0 0 0 12px;
    font-family: Arial, Helvetica, sans-serif;
    color:#7f879e;
    font-size: 14px;
    font-weight: bold;
    overflow: hidden;
    margin: 0px;

    }
    .AccordionPanelContent2 {
    letter-spacing: -0.05em;
    background-image: url(../images/new/spry/meun_grey.gif);
    background-repeat: repeat-y;
    padding: 0 0 0 12px;
    font-family: Arial, Helvetica, sans-serif;
    color:#7f879e;
    font-size: 14px;
    font-weight: bold;
    overflow: auto;
    margin: 0px;
    height: 200px;
    }

    /* This is an example of how to change the appearance of the panel tab that is
    * currently open. The class "AccordionPanelOpen" is programatically added and removed
    * from panels as the user clicks on the tabs within the Accordion.
    */
    .AccordionPanelOpen .AccordionPanelTab {
    background-color: #EEEEEE;
    }

    /* This is an example of how to change the appearance of the panel tab as the
    * mouse hovers over it. The class "AccordionPanelTabHover" is programatically added
    * and removed from panel tab containers as the mouse enters and exits the tab container.
    */
    .AccordionPanelTabHover {
    color: #555555;
    }
    .AccordionPanelOpen .AccordionPanelTabHover {
    color: #555555;
    }

    /* This is an example of how to change the appearance of all the panel tabs when the
    * Accordion has focus. The "AccordionFocused" class is programatically added and removed
    * whenever the Accordion gains or loses keyboard focus.
    */
    .AccordionFocused .AccordionPanelTab {
    background-color: #3399FF;
    }

    /* This is an example of how to change the appearance of the panel tab that is
    * currently open when the Accordion has focus.
    */
    .AccordionFocused .AccordionPanelOpen .AccordionPanelTab {
    background-color: #33CCFF;
    }
    Ant Lavelle is offline Junior Member
    Join Date
    Sep 2010
    Posts
    1

Posting Permissions

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

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139