Spry expanding region - wrong CSS shows?

I'm using a series of expanding regions. Via their CSS, I'm
displaying one background image in the tab when open, a different
one when closed.
Two of the regions I have set to start in their opened state.
Although they are open, they are displaying the "closed" image. If
I close them, then open them, then they correctly display the
"open" image.
Why is this? How can I ensure that the divs that start "open"
display the image set in the css?
.CollapsiblePanelTab {
...other stuff...
background: #899F55 url(../images/plus.gif) no-repeat 5px
center;
border-bottom: 1px solid #686155;
.CollapsiblePanelOpen .CollapsiblePanelTab {
background: #899F55 url(../images/minus.gif) no-repeat 5px
center;

The partial answer is that I was using incorrect syntax. I
started going through the SimpleAutosuggest, and found the
following:
quote:
Spry.Data.Region.addObserver(regionID, { onPostUpdate:
function(notifier, data) {
self.attachClickBehaviors();
Which was basically the syntax I was looking for, which
allows me to use the object notation instead of the function
notation, and call through an object that each autosuggest object
is tied to.
However, it brings me back to my original problem. I've gone
through the Region Observer Notifications documentation here:
http://livedocs.adobe.com/en_US/Spry/SDG/help.html?content=WS57937FB2-D8C1-424d-B3E4-655FD 7A7899B.html
... and in another place, I read that in a callback, you cannot
pass variables because it will run the call back immediately, and
not when you expect it to. That seems to be my problem, but
regardless of if I pass parameters, I get no call back when I
expect it. If I pass parameters, I get the call back immediately,
but not later, if I don't pass parameters, I never get the
callback.
It's got to be something dumb, but I don't see what it is,
and unfortunately, I have no way of putting the code outside our
firewall until it goes live. :(
Thank you for trying.

Similar Messages

  • Spry Expanding Region problem

    I have a group of Spry expanding regions on my page. I have
    modified the default CSS to that an open tab uses one background
    image and a closed one a different image (think of the plus/minus
    of a tree control, or Windows Explorer).
    I works fine, except that I've set two regions to be open by
    default -- yet these two show the "closed" CSS background image. If
    I close them, and re-open, then they show the "open" image.
    Why is this, and how can i fix this?

    Thanks for your response. The website link is:
    http://www.jobs4theenvironment.com/index6.html.
    You will not be able to access every link on all the pages because
    I am re-creating the site and have not uploaded all of them to the
    server, but the primary pages are there for you to see. Any help
    with this Spry Menu bar issue would be fantastic. It's been really
    frustrating and I'm too much of a novice to figure out what went
    wrong.
    Thanks,
    Derek

  • Spry 2.0 menu not showing in IE8

    I have a webpage with a horizontal and vertical Spry 2.0 menu on the page. Both menus work correctly in Firefox, Chrome, Safari, and IE9, but the vertical menu does not show at all in IE8. In addition in IE8 the browser scroll bar disappears when the vertical menu is added.  The test page is http://www.njslom.org/001banner5.html
    I am using CS5 and the Spry 2.0 Widget in an html template.
    Any help at all would be appreciated.
    [email protected]
    Page code
    <!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" xmlns:spry="http://ns.adobe.com/spry">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <!-- TemplateBeginEditable name="doctitle" -->
    <title>Untitled Document</title>
    <!-- TemplateEndEditable -->
    <!-- TemplateBeginEditable name="head" -->
    <!-- TemplateEndEditable -->
    <style type="text/css">
    body,td,th {
    font-family: Arial, Helvetica, sans-serif;
    body {
    background-color: #EBEBEB;
    margin-top: 0px;
    </style>
    <script src="/Spry-UI-1.7/includes/SpryDOMUtils.js" type="text/javascript"></script>
    <script src="/Spry-UI-1.7/includes/SpryDOMEffects.js" type="text/javascript"></script>
    <script src="/Spry-UI-1.7/includes/SpryWidget.js" type="text/javascript"></script>
    <script src="/Spry-UI-1.7/includes/SpryMenu.js" type="text/javascript"></script>
    <script src="/Spry-UI-1.7/includes/plugins/MenuBar2/SpryMenuBarKeyNavigationPlugin.js" type="text/javascript"></script>
    <script src="/Spry-UI-1.7/includes/plugins/MenuBar2/SpryMenuBarIEWorkaroundsPlugin.js" type="text/javascript"></script>
    <link href="/Spry-UI-1.7/css/Menu/basic/SpryMenuBasic.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
    #MenuPublic1  {
    background-color:#F2F2F2;
    font-family: Arial, Helvetica, sans-serif; /* Specify fonts on on MenuBar and subMenu MenuItemContainer, so MenuItemContainer,
                MenuItem, and MenuItemLabel
                at a given level all use same definition for ems.
                Note that this means the size is also inherited to child submenus,
                so use caution in using relative sizes other than
                100% on submenu fonts. */
    font-weight: bold;
    font-size: 12px;
    font-style: normal;
    padding:0;
    border-color: #ffffff #ffffff #ffffff #ffffff;
    border-width:0px;
    border-style: none none none none;
    /* Caution: because ID+class selectors do not work properly in IE6, but we want to restrict these rules to just this
    widget instance, we have used string-concatenated classnames for our selectors for the layout type of the menubar
    in this section. These have very low specificity, so be careful not to accidentally override them. */
    .MenuBar br { /* using just a class so it has same specificity as the ".MenuPublic1FixedCentered br" rule bleow */
    display:none;
    .MenuPublic1LeftShrink {
    float: left; /* shrink to content, as well as float the MenuBar */
    width: auto;
    .MenuPublic1RightShrink {
    float: right; /* shrink to content, as well as float the MenuBar */
    width: auto;
    .MenuPublic1FixedLeft {
    float: left;
    width: 70em;
    .MenuPublic1FixedCentered {
    float: none;
    width: 70em;
    margin-left:auto;
    margin-right:auto;
    .MenuPublic1FixedCentered br {
    clear:both;
    display:block;
    .MenuPublic1FixedCentered .SubMenu br {
    display:none;
    .MenuPublic1Fullwidth {
    float: left;
    width: 100%;
    /* Top level menubar items - these actually apply to all items, and get overridden for 1st or successive level submenus */
    #MenuPublic1  .MenuItemContainer {
    padding: 0px 0px 0px 0px;
    margin: 0;  /* Zero out margin  on the item containers. The MenuItem is the active hover area.
        For most items, we have to do top or bottom padding or borders only on the MenuItem
        or a child so we keep the entire submenu tiled with items.
        Setting this to 0 avoids "dead spots" for hovering. */
    #MenuPublic1  .MenuItem {
    padding: 0px 0px 0px 0px;
    background-color:#F2F2F2;
    border-width:0px;
    border-color: #cccccc #ffffff #cccccc #ffffff;
    border-style: none solid none solid;
    #MenuPublic1  .MenuItemFirst {
    border-style: none none none none;
    #MenuPublic1 .MenuItemLast {
    border-style: none solid none none;
    #MenuPublic1  .MenuItem  .MenuItemLabel{
    text-align:center;
    line-height:1.4em;
    color:#ffffff;
    background-color:#F2F2F2;
    padding: 7px 28px 7px 28px;
    width: 10em;
    width:auto;
    .SpryIsIE6 #MenuPublic1  .MenuItem  .MenuItemLabel{
    width:1em; /* Equivalent to min-width in modern browsers */
    /* First level submenu items */
    #MenuPublic1 .SubMenu  .MenuItem {
    font-family: Arial, Helvetica, sans-serif;
    font-weight: bold;
    font-size: 12px;
    font-style: normal;
    background-color:#F2F2F2;
    padding:0px 2px 0px 0px;
    border-width:1px;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    /* Border styles are overriden by first and last items */
    border-style: solid solid none solid;
    #MenuPublic1  .SubMenu .MenuItemFirst {
    border-style: solid solid none solid;
    #MenuPublic1  .SubMenu .MenuItemFirst .MenuItemLabel{
    padding-top: 4px;
    #MenuPublic1 .SubMenu .MenuItemLast {
    border-style: solid solid solid solid;
    #MenuPublic1 .SubMenu .MenuItemLast .MenuItemLabel{
    padding-bottom: 4px;
    #MenuPublic1 .SubMenu .MenuItem .MenuItemLabel{
    text-align:left;
    line-height:1em;
    background-color:#F2F2F2;
    color:#ffffff;
    padding: 4px 12px 4px 5px;
    width: 175px;
    /* Hover states for containers, items and labels */
    #MenuPublic1 .MenuItemHover {
    background-color: #69adee;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    #MenuPublic1 .MenuItemWithSubMenu.MenuItemHover .MenuItemLabel{
    background-color: #69adee; /* consider exposing this prop separately*/
    color: #000000;
    #MenuPublic1 .MenuItemHover .MenuItemLabel{
    background-color: #69adee;
    color: #000000;
    #MenuPublic1 .SubMenu .MenuItemHover {
    background-color: #69adee;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    #MenuPublic1 .SubMenu .MenuItemHover .MenuItemLabel{
    background-color: #69adee;
    color: #000000;
    /* Submenu properties -- First level of submenus */
    #MenuPublic1 .SubMenuVisible {
    background-color: #F2F2F2;
    min-width:0%;  /* This keeps the menu from being skinnier than the parent MenuItemContainer - nice to have but not available on ie6 */
    border-color: #ffffff #ffffff #ffffff #ffffff;
    border-width:0px;
    border-style: none none none none;
    #MenuPublic1.MenuBar .SubMenuVisible {/* For Horizontal menubar only */
    top: 100%; /* 100% is at the bottom of parent menuItemContainer */
    left:0px; /* 'left' may need tuning depending upon borders or padding applied to menubar MenuItemContainer or MenuItem,
         and your personal taste.
         0px will left align the dropdown with the content area of the MenuItemContainer. Assuming you keep the margins 0
         on MenuItemContainer and MenuItem on the parent
         menubar, making this equal the sum of the MenuItemContainer & MenuItem padding-left will align
         the dropdown with the left of the menu item label.*/
    z-index:10;
    #MenuPublic1.MenuBarVertical .SubMenuVisible {
    top: 0px;
    left:100%;
    min-width:0px; /* Do not neeed to match width to parent MenuItemContainer - items will prevent total collapse */
    /* Submenu properties -- Second level submenu and beyond - these are visible descendents of .MenuLevel1 */
    #MenuPublic1 .MenuLevel1 .SubMenuVisible {
    background-color: #F2F2F2;
    min-width:0px; /* Do not neeed to match width to parent MenuItemContainer - items will prevent total collapse*/
    top: 0px; /* If desired, you can move this down a smidge to separate top item''s submenu from menubar -
        that is really only needed for submenu on first item of MenuLevel1, or you can make it negative to make submenu more
        vertically 'centered' on its invoking item */
    left:100%; /* If you want to shift the submenu left to partially cover its invoking item, you can add a margin-left with a
        negative value to this rule. Alternatively, if you use fixed-width items, you can change this left value
        to use px or ems to get the offset you want. */
    /* IE6 rules - you can delete these if you do not want to support IE6 */
    /* A note about multiple classes in IE6.
    * Some of the rules above use multiple class names on an element for selection, such as "hover" (MenuItemHover) and "has a subMenu" (MenuItemWithSubMenu),
    * giving the selector '.MenuItemWithSubMenu.MenuItemHover'.
    * Unfortunately IE6 does not support using mutiple classnames in a selector for an element. For a selector such as '.foo.bar.baz', IE6 ignores
    * all but the final classname (here, '.baz'), and sets the specificity accordingly, counting just one of those classs as significant. To get around this
    * problem, we use the plugin in SpryMenuBarIEWorkaroundsPlugin.js to generate compound classnames for IE6, such as 'MenuItemWithSubMenuHover'.
    * Since there are a lot of these needed, the plugin does not generate the extra classes for modern browsers, and we use the CSS2 style mutltiple class
    * syntax for that. Since IE6 both applies rules where
    * it should not, and gets the specificity wrong too, we have to order rules carefully, so the rule misapplied in IE6 can be overridden.
    * So, we put the multiple class rule first. IE6 will mistakenly apply this rule.  We follow this with the single-class rule that it would
    * mistakenly override, making sure the  misinterpreted IE6 specificity is the same as the single-class selector, so the latter wins.
    * We then create a copy of the multiple class rule, adding a '.SpryIsIE6' class as context, and making sure the specificity for
    * the selector is high enough to beat the single-class rule in the "both classes match" case. We place the IE6 rule at the end of the
    * css style block to make it easy to delete if you want to drop IE6 support.
    * If you decide you do not need IE6 support, you can get rid of these, as well as the inclusion of the SpryMenuBarIEWorkaroundsPlugin.js script.
    * The 'SpryIsIE6' class is placed on the HTML element by  the script in SpryMenuBarIEWorkaroundsPlugin.js if the browser is Internet Explorer 6. This avoids the necessity of IE conditional comments for these rules.
    .SpryIsIE6 #MenuPublic1 .MenuBarView .MenuItemWithSubMenuHover .MenuItemLabel /* IE6 selector  */{
    background-color: #69adee; /* consider exposing this prop separately*/
    color: #000000;
    .SpryIsIE6 #MenuPublic1 .MenuBarView .SubMenu .MenuItemWithSubMenuHover .MenuItemLabel/* IE6 selector  */{
    background-color: #69adee; /* consider exposing this prop separately*/
    color: #000000;
    .SpryIsIE6 #MenuPublic1 .SubMenu .SubMenu  /* IE6 selector  */{
    margin-left: -0px; /* Compensates for at least part of an IE6 "double padding" version of the "double margin" bug */
    /* EndOAWidget_Instance_2141544 */
    </style>
    <script type="text/xml">
    <!--
    <oa:widgets>
      <oa:widget wid="2141544" binding="#MenuPublic1" />
      <oa:widget wid="2141544" binding="#MenuPublic1_2" />
    </oa:widgets>
    -->
    </script>
    <style type="text/css">
    /* BeginOAWidget_Instance_2141544: #MenuPublic1_2 */
    /* Settable values for skinning a Basic menu via presets. If presets are not sufficient, most skinning should be done in
    these rules, with the exception of the images used for down or right pointing arrows, which are in the file SpryMenuBasic.css
      These assume the following widget classes for menu layout (set in a preset)
    .MenuBar - Applies to all menubars - default is horizontal bar, all submenus are vertical - 2nd level subs and beyond are pull-right.
    .MenuBarVertical - vertical main bar; all submenus are pull-right.
    You can also pass in extra classnames to set your desired top level menu bar layout. Normally, these are set by using a preset.
    They only apply to horizontal menu bars:
      MenuBarLeftShrink - The menu bar will be horizontally 'shrinkwrapped' to be just large enough to hold its items, and left aligned
      MenuBarRightShrink - Just like MenuBarLeftShrink, but right aligned
      MenuBarFixedLeft - Fixed at a specified width set in the rule '.MenuBarFixedLeft', and left aligned. 
      MenuBarFixedCentered -  - Fixed at a specified width set in the rule '.MenuBarFixedCentered',
          and centered in its parent container.
      MenuBarFullwidth - Grows to fill its parent container width.
    In general, all rules specified in this file are prefixed by #MenuPublic1_2 so they only apply to instances of the widget inserted along
    with the rules. This permits use of multiple MenuBarBasic widgets on the same page with different layouts. Because of IE6 limitations,
    there are a few rules where this was not possible. Those rules are so noted in comments.
    #MenuPublic1_2  {
    background-color:#8ca7d2;
    font-family: Arial, Helvetica, sans-serif; /* Specify fonts on on MenuBar and subMenu MenuItemContainer, so MenuItemContainer,
                MenuItem, and MenuItemLabel
                at a given level all use same definition for ems.
                Note that this means the size is also inherited to child submenus,
                so use caution in using relative sizes other than
                100% on submenu fonts. */
    font-weight: bold;
    font-size: 12px;
    font-style: normal;
    padding:0;
    border-color: #ffffff #ffffff #ffffff #ffffff;
    border-width:0px;
    border-style: none none none none;
    /* Caution: because ID+class selectors do not work properly in IE6, but we want to restrict these rules to just this
    widget instance, we have used string-concatenated classnames for our selectors for the layout type of the menubar
    in this section. These have very low specificity, so be careful not to accidentally override them. */
    .MenuBar br { /* using just a class so it has same specificity as the ".MenuPublic1_2FixedCentered br" rule bleow */
    display:none;
    .MenuPublic1_2LeftShrink {
    float: left; /* shrink to content, as well as float the MenuBar */
    width: auto;
    .MenuPublic1_2RightShrink {
    float: right; /* shrink to content, as well as float the MenuBar */
    width: auto;
    .MenuPublic1_2FixedLeft {
    float: left;
    width: 175px;
    .MenuPublic1_2FixedCentered {
    float: none;
    width: 175px;
    margin-left:auto;
    margin-right:auto;
    .MenuPublic1_2FixedCentered br {
    clear:both;
    display:block;
    .MenuPublic1_2FixedCentered .SubMenu br {
    display:none;
    .MenuPublic1_2Fullwidth {
    float: left;
    width: 100%;
    /* Top level menubar items - these actually apply to all items, and get overridden for 1st or successive level submenus */
    #MenuPublic1_2  .MenuItemContainer {
    padding: 0px 0px 0px 0px;
    margin: 0;  /* Zero out margin  on the item containers. The MenuItem is the active hover area.
        For most items, we have to do top or bottom padding or borders only on the MenuItem
        or a child so we keep the entire submenu tiled with items.
        Setting this to 0 avoids "dead spots" for hovering. */
    #MenuPublic1_2  .MenuItem {
    padding: 0px 24px 0px 0px;
    background-color:#8ca7d2;
    border-width:0px;
    border-color: #cccccc #ffffff #cccccc #ffffff;
    border-style: none solid none solid;
    #MenuPublic1_2  .MenuItemFirst {
    border-style: none none none none;
    #MenuPublic1_2 .MenuItemLast {
    border-style: none solid none none;
    #MenuPublic1_2  .MenuItem  .MenuItemLabel{
    text-align:left;
    line-height:1.4em;
    color:#ffffff;
    background-color:#8ca7d2;
    padding: 6px 10px 6px 10px;
    width: 175px;
    .SpryIsIE6 #MenuPublic1_2  .MenuItem  .MenuItemLabel{
    width:1em; /* Equivalent to min-width in modern browsers */
    /* First level submenu items */
    #MenuPublic1_2 .SubMenu  .MenuItem {
    font-family: Arial, Helvetica, sans-serif;
    font-weight: bold;
    font-size: 12px;
    font-style: italic;
    background-color:#0066ff;
    padding:0px 2px 0px 0px;
    border-width:1px;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    /* Border styles are overriden by first and last items */
    border-style: solid solid none solid;
    #MenuPublic1_2  .SubMenu .MenuItemFirst {
    border-style: solid solid none solid;
    #MenuPublic1_2  .SubMenu .MenuItemFirst .MenuItemLabel{
    padding-top: 4px;
    #MenuPublic1_2 .SubMenu .MenuItemLast {
    border-style: solid solid solid solid;
    #MenuPublic1_2 .SubMenu .MenuItemLast .MenuItemLabel{
    padding-bottom: 4px;
    #MenuPublic1_2 .SubMenu .MenuItem .MenuItemLabel{
    text-align:left;
    line-height:1em;
    background-color:#0066ff;
    color:#ffffff;
    padding: 4px 12px 4px 5px;
    width: 175px;
    /* Hover states for containers, items and labels */
    #MenuPublic1_2 .MenuItemHover {
    background-color: #cae9fd;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    #MenuPublic1_2 .MenuItemWithSubMenu.MenuItemHover .MenuItemLabel{
    background-color: #cae9fd; /* consider exposing this prop separately*/
    color: #000000;
    #MenuPublic1_2 .MenuItemHover .MenuItemLabel{
    background-color: #cae9fd;
    color: #000000;
    #MenuPublic1_2 .SubMenu .MenuItemHover {
    background-color: #69adee;
    border-color: #cccccc #cccccc #cccccc #cccccc;
    #MenuPublic1_2 .SubMenu .MenuItemHover .MenuItemLabel{
    background-color: #69adee;
    color: #000000;
    /* Submenu properties -- First level of submenus */
    #MenuPublic1_2 .SubMenuVisible {
    background-color: #0066ff;
    min-width:0%;  /* This keeps the menu from being skinnier than the parent MenuItemContainer - nice to have but not available on ie6 */
    border-color: #ffffff #ffffff #ffffff #ffffff;
    border-width:0px;
    border-style: none none none none;
    #MenuPublic1_2.MenuBar .SubMenuVisible {/* For Horizontal menubar only */
    top: 100%; /* 100% is at the bottom of parent menuItemContainer */
    left:0px; /* 'left' may need tuning depending upon borders or padding applied to menubar MenuItemContainer or MenuItem,
         and your personal taste.
         0px will left align the dropdown with the content area of the MenuItemContainer. Assuming you keep the margins 0
         on MenuItemContainer and MenuItem on the parent
         menubar, making this equal the sum of the MenuItemContainer & MenuItem padding-left will align
         the dropdown with the left of the menu item label.*/
    z-index:10;
    #MenuPublic1_2.MenuBarVertical .SubMenuVisible {
    top: 0px;
    left:100%;
    min-width:0px; /* Do not neeed to match width to parent MenuItemContainer - items will prevent total collapse */
    /* Submenu properties -- Second level submenu and beyond - these are visible descendents of .MenuLevel1 */
    #MenuPublic1_2 .MenuLevel1 .SubMenuVisible {
    background-color: #0066ff;
    min-width:0px; /* Do not neeed to match width to parent MenuItemContainer - items will prevent total collapse*/
    top: 0px; /* If desired, you can move this down a smidge to separate top item''s submenu from menubar -
        that is really only needed for submenu on first item of MenuLevel1, or you can make it negative to make submenu more
        vertically 'centered' on its invoking item */
    left:100%; /* If you want to shift the submenu left to partially cover its invoking item, you can add a margin-left with a
        negative value to this rule. Alternatively, if you use fixed-width items, you can change this left value
        to use px or ems to get the offset you want. */
    /* IE6 rules - you can delete these if you do not want to support IE6 */
    /* A note about multiple classes in IE6.
    * Some of the rules above use multiple class names on an element for selection, such as "hover" (MenuItemHover) and "has a subMenu" (MenuItemWithSubMenu),
    * giving the selector '.MenuItemWithSubMenu.MenuItemHover'.
    * Unfortunately IE6 does not support using mutiple classnames in a selector for an element. For a selector such as '.foo.bar.baz', IE6 ignores
    * all but the final classname (here, '.baz'), and sets the specificity accordingly, counting just one of those classs as significant. To get around this
    * problem, we use the plugin in SpryMenuBarIEWorkaroundsPlugin.js to generate compound classnames for IE6, such as 'MenuItemWithSubMenuHover'.
    * Since there are a lot of these needed, the plugin does not generate the extra classes for modern browsers, and we use the CSS2 style mutltiple class
    * syntax for that. Since IE6 both applies rules where
    * it should not, and gets the specificity wrong too, we have to order rules carefully, so the rule misapplied in IE6 can be overridden.
    * So, we put the multiple class rule first. IE6 will mistakenly apply this rule.  We follow this with the single-class rule that it would
    * mistakenly override, making sure the  misinterpreted IE6 specificity is the same as the single-class selector, so the latter wins.
    * We then create a copy of the multiple class rule, adding a '.SpryIsIE6' class as context, and making sure the specificity for
    * the selector is high enough to beat the single-class rule in the "both classes match" case. We place the IE6 rule at the end of the
    * css style block to make it easy to delete if you want to drop IE6 support.
    * If you decide you do not need IE6 support, you can get rid of these, as well as the inclusion of the SpryMenuBarIEWorkaroundsPlugin.js script.
    * The 'SpryIsIE6' class is placed on the HTML element by  the script in SpryMenuBarIEWorkaroundsPlugin.js if the browser is Internet Explorer 6. This avoids the necessity of IE conditional comments for these rules.
    .SpryIsIE6 #MenuPublic1_2 .MenuBarView .MenuItemWithSubMenuHover .MenuItemLabel /* IE6 selector  */{
    background-color: #cae9fd; /* consider exposing this prop separately*/
    color: #000000;
    .SpryIsIE6 #MenuPublic1_2 .MenuBarView .SubMenu .MenuItemWithSubMenuHover .MenuItemLabel/* IE6 selector  */{
    background-color: #69adee; /* consider exposing this prop separately*/
    color: #000000;
    .SpryIsIE6 #MenuPublic1_2 .SubMenu .SubMenu  /* IE6 selector  */{
    margin-left: -0px; /* Compensates for at least part of an IE6 "double padding" version of the "double margin" bug */
    /* EndOAWidget_Instance_2141544 */
    .text-white { color: #FFF;
    </style>
    </head>
    <body>
    <table width="950" border="0" align="center" cellpadding="7" cellspacing="0">
      <tr>
        <td width="284" bgcolor="#0000CC"><strong class="text-white">Serving Municipal Government in <br />
    New Jersey Since 1915</strong></td>
        <td width="305" bgcolor="#0000CC"><div align="center"><div align="center">    <!-- Begin PicoSearch Query Box -->
    <table style="background-color:#004d8c" cellspacing="0" cellpadding="0" border="0">
    <tr><td>
    <form style="margin:0;" method="get" action="http://www.picosearch.com/cgi-bin/ts.pl">
    <input type="hidden" name="index" value="520788" />
    <table style="background-color:#004d8c" cellspacing="2" cellpadding="0" border="0">
    <tr><td><a href="http://www.picosearch.com/cgi-bin/index.pl?wherefrom=picobox&amp;type=allhttp://www.picosearch.com/cgi-bin/index.pl?wherefrom=picobox&type=all"></a></td>
      <td align="right"><input type="text" name="query"  value="" size="20" />
      <input type="submit" value="GO" name="search2" /></td>
    </tr>
    </table>
    </form>
    </td></tr></table>
    <span style="white-space: nowrap;">
    </span><!-- End PicoSearch Query Box --></div></div></td>
        <td width="319" bgcolor="#0000CC"><div align="right" class="text-white"><a href="http://www.njslom.org" class="text-white"><strong>HOME</strong></a> | <a href="http://www.njlmef.org" class="text-white"><strong>NJLM Educational Foundation </strong></a></div></td>
      </tr>
    </table>
    <table width="950" border="0" align="center" cellpadding="0" cellspacing="0" bgcolor="#F2F2F2">
      <tr>
        <td width="135"><img src="/images-head/head-logo-1.jpg" width="128" height="200" /></td>
        <td width="815" valign="top"><p> </p>
          <p> </p>
          <p> I will be adding the Spry Content Slideshow in this area</p>
        </td>
      </tr>
    </table>
    <table width="950" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td colspan="2" bgcolor="#F2F2F2"><ul id="MenuPublic1">
          <li> <a href="#">Classifieds</a>
          <ul>
            <li><a href="#">Classifieds &amp; Job Listings</a></li>
          </ul></li>
          <li> <a href="#">NJ Municipalities Magazine</a>
            <ul>
              <li> <a href="#">Current Issue</a></li>
              <li> <a href="#">Advertise</a> </li>
              <li> <a href="#">Subscribe</a> </li>
              <li> <a href="#">Submission Guidelines</a></li>
            </ul>
          </li>
          <li> <a href="#">Seminars & Events</a>
          <ul>
            <li><a href="#">Events &amp; Registration</a></li>
            <li><a href="#">CEU Requirements</a></li>
          </ul>
          </li>
          <li> <a href="#">Legislation</a>
            <ul>
              <li><a href="#">Legislative Committee</a></li>
              <li><a href="#">Legislative Priorities</a></li>
              <li><a href="#">Legislative Bulletin</a></li>
              <li><a href="#">Conference Resolutions</a></li>
          </ul></li>
           <li> <a href="#">Issues & Documents</a>
            <ul>
              <li><a href="#">Issue Alerts</a></li>
              <li><a href="#">Press & Media</a></li>
              <li><a href="#">Publications</a></li>
              <li><a href="#">Sample Resolutions</a></li>
              <li><a href="#">League Testimony</a></li>
          </ul></li>
           <li> <a href="#">NJLM Directories</a>
            <ul>
              <li><a href="#">Staff</a></li>
              <li><a href="#">Executive Board</a></li>
              <li><a href="#">League Officers</a></li>
              <li><a href="#">League Attorneys</a></li>
              <li><a href="#">League Affiliates</a></li>
              <li><a href="#">League Committees</a></li>
          </ul></li>
            <p>
              <script type="text/javascript">
    // BeginOAWidget_Instance_2141544: #MenuPublic1
    var MenuPublic1 = new Spry.Widget.MenuBar2("#MenuPublic1", {
          widgetID: "MenuPublic1",
       widgetClass: "MenuBar  MenuPublic1LeftShrink",
       insertMenuBarBreak: true,
          mainMenuShowDelay: 100,
          mainMenuHideDelay: 200,
          subMenuShowDelay: 200,
          subMenuHideDelay: 200
    // EndOAWidget_Instance_2141544
            </script>
        </p></td>
      </tr>
      <tr>
        <td width="175" valign="top" bgcolor="#F2F2F2"><p> </p>
          <ul id="MenuPublic1_2">
            <li> <a href="#">Home</a></li>
            <li> <a href="#">Entertainment</a>
              <ul>
                <li> <a href="#">TV Listings</a></li>
                <li> <a href="#">Music</a>
                  <ul>
                    <li> <a href="#">Hits</a></li>
                    <li> <a href="#">Ragga</a>
                      <ul>
                        <li> <a href="#">Roots</a></li>
                        <li> <a href="#">Reggaeton</a></li>
                        <li> <a href="#">Dancehall</a></li>
                      </ul>
                    </li>
                    <li> <a href="#">Country</a></li>
                  </ul>
                </li>
                <li> <a href="#">The Dirt</a>
                  <ul>
                    <li> <a href="#">Hollywood</a></li>
                    <li> <a href="#">NY Beat</a></li>
                    <li> <a href="#">London Scene</a></li>
                  </ul>
                </li>
                <li> <a href="#">The Web</a></li>
              </ul>
            </li>
            <li> <a href="#">Politics</a></li>
            <li> <a href="#">Sports</a>
              <ul>
                <li> <a href="#">Football</a></li>
                <li> <a href="#">Baseball</a></li>
                <li> <a href="#">Basketball</a></li>
                <li> <a href="#">Racing</a>
                  <ul>
                    <li> <a href="#">F1</a></li>
                    <li> <a href="#">Indy Car</a></li>
                    <li> <a href="#">Stock Car</a></li>
                  </ul>
                </li>
              </ul>
            </li>
          </ul>
          <script type="text/javascript">
    // BeginOAWidget_Instance_2141544: #MenuPublic1_2
    var MenuPublic1_2 = new Spry.Widget.MenuBar2("#MenuPublic1_2", {
          widgetID: "MenuPublic1_2",
       widgetClass: "MenuBar MenuBarVertical MenuPublic1_2MenuBarVerticalLeftShrink",
       insertMenuBarBreak: true,
          mainMenuShowDelay: 100,
          mainMenuHideDelay: 200,
          subMenuShowDelay: 200,
          subMenuHideDelay: 200
    // EndOAWidget_Instance_2141544
          </script>
    <p> </p></td>
        <td width="773" valign="top" bgcolor="#F2F2F2"><!-- TemplateBeginEditable name="EditRegion3" -->
          <p>EditRegion3</p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p> </p>
          <p>This is the bottom of the page</p>
        <!-- TemplateEndEditable --></td>
      </tr>
    </table>
    </body>
    </html>

    I get the following error message
    Perhaps you could have a look at KB927917
    Gramps

  • Spry Master Detail section not showing in IE after addObserver

    So, I have this cool thing almost done and I get it close and then it goes blank in IE - FireFox is fine, Safari PC is blank, Chrome is blank too.
    http://ryanmillsdesignstudio.com/MasterDetail.cfm
    As soon as I add the addaobserver
    <script type="text/javascript" language="javascript">
    <!--
    var dsPortfolio = new Spry.Data.XMLDataSet("Residential.xml", "gallery/album/img", {sortOnLoad: "@src", sortOrderOnLoad: "ascending"});
    //-->
    <!--
    Spry.Data.Region.addObserver('items', {
         onPostUpdate : function(observer, region){
              // slider code
    // execute your scripts when DOM is ready. this is a good habit
    $(function() {       
        // initialize scrollable
        $("div.scrollable").scrollable();   
    $(function() {
        /* execute this script block when page is ready to be scripted */
        // select items under the second scrollable and do something when they are clicked
        $("div.scrollable:eq(1) div.items div").click(function() {
            // perform the effect
            $(this).fadeOut().fadeIn();
    // custom easing called "custom"
    $.easing.custom = function (x, t, b, c, d) {
        var s = 1.70158;
        if ((t/=d/2) < 1) return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b;
        return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b;
    // use the custom easing
    $("div.scrollable").scrollable({easing: 'custom', speed: 700});
    $(document).ready(function(){
    $.ajax({
            type: "GET",
        url: "Residential.xml",
        dataType: "xml",
        success: function(xml) {
              //END scrollable
    }); //END observer
    </script>
    nor can I get the spry detail region work when I click on the image to show the lager image up top.

    No clue, as its something that your jQuery plugin does. Probably some CSS issue. I suggest you post that issue in the jQuery tools forum.
    And a comment about your region observer, again, there are items function that do not need to be there, they are obsoleet and even duplicate.\
    Spry.Data.Region.addObserver('items', {
         onPostUpdate : function(observer, region){
              // your slider code here
    // execute your scripts when DOM is ready. this is a good habit
    $(function() { // NOT NEEDED BECAUSE YOUR DOM IS READY WHEN THE OBSERVER FIRES
    // initialize scrollable
         $("div.scrollable").scrollable();     
    $(document).ready(function(){ // YOU ARE DOING A AJAX CALL, BUT YOU ARE DOING NOTHING WITH THE XML
    $.ajax({
            type: "GET",
         url: "Residential.xml",
         dataType: "xml",
         success: function(xml) {
                //END scrollable
    }); //END observer
    I made all useless scripts red and bold, and added the reason in comments. Sorry about the caps, forgot that it was on

  • Help with Spry Rating Widget within a Spry Repeating Region

    My link  http://www.youthinkyougotitbad.com
    This is a long question, but it seems to me if answered somewhere it could help alot of people in the spry community creating comment boards as it uses three important spry widgets: rating, repeating, and tabbed panels. I am trying to use spry rating widget within a spry repeating region within a spry tabbed panel with xml. I was trying to go with the pulse light script (http://forums.adobe.com/message/3831721#3831721) but Gramps told me about the spry rating widget. But I have ran into a couple more problems. First, I couldnt find that much information on the forums or online about how to do the php page with the spry rating widget. None of these have any information on how to do it:
    http://labs.adobe.com/technologies/spry/articles/rating_overview/index .html
    http://labs.adobe.com/technologies/spry/articles/data_api/apis/rating. html
    http://labs.adobe.com/technologies/spry/samples/rating/RatingSample.ht ml
    And it seems that the official examples are so poor (or I am just ignorant, which def could be a possiblity) it shows
    to set the initial rating value from the server, but uses a static value of 4
    http://labs.adobe.com/technologies/spry/samples/rating/RatingSample.html
    <span id="initialValue_dynamic" class="ratingContainer">
             <span class="ratingButton"></span>
             <span class="ratingButton"></span>
             <span class="ratingButton"></span>
             <span class="ratingButton"></span>
             <span class="ratingButton"></span>      
             <input id="spryrating1_val" type="text" name="spryrating1" value="4" readonly="readonly" />
             <span class="ratingRatedMsg sample">Thanks for your rating!</span>
    </span>
    <script>
    var initialValue_dynamic = new Spry.Widget.Rating("initialValue_dynamic", {ratingValueElement:'spryrating1_val'});
    </script>
    I finally found a site that has the php and mysql setup.
    http://www.pixelplant.ro/en/articles/article-detail/article/adobe-widgets-for-download.htm l
    But its not perfect. It has the same problem that I ran into with Pulse light, that you had to use php echo within the spry repeating region to set the initial value from the server:
    <span id="spryrating1" class="ratingContainer">
             <span class="ratingButton"></span>
                <input type="text" id="ratingValue" name="dynamic_rate" value="<?php echo $row['average']?>"/>
            </span>
            <script type="text/javascript"
                var rating1 = new Spry.Widget.Rating("spryrating1", {ratingValueElement:'ratingValue', afterRating:'serverValue', saveUrl: 'save.php?id=spryrating1&val=@@ratingValue@@'});
            </script>
    So instead, I tried with three of my panels (www.youthinkyougotitbad.com) to get the average rating from xml by using the following queries:
    Recent
    Returns the blurts in most recent order along with average rating
    SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt Group By Id_blurt ORDER BY Blurt.`Date` DESC
    Wet Eyed
    Returns the blurts in highest ratings order along with the average rating
    SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt, DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt AND ratings.rating_value > 0.1 Group By Id_blurt ORDER BY average_r Desc
    Dry Eyed
    Returns the blurts in lowest rating order along with the average rating
    SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt, DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt AND ratings.rating_value > 0.1 Group By Id_blurt ORDER BY average_r
    These all return the correct xml in the correct order.And they return the average rating of each blurt which I can send to my page with xml.
    My first question is that I dont know how to configure the query on my fourth panel Empathized & Advised the same way because it already has a Group By for the Comment Id.
    SELECT `Comment`.id_Blurt, COUNT(*) as frequency, Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt, DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date FROM Blurt, `Comment` WHERE Blurt.Id_blurt = `Comment`.id_Blurt GROUP BY `Comment`.id_Blurt ORDER BY COUNT(*) DESC";
    Not sure if you guys need more information to understand that all, if so just ask.
    So after I get my average value through xml to the first three panels, I set my spry repeating region up like this:
    (Blurt panel)
    <div spry:region="pv1" spry:repeatchildren="pv1">           
               <div class="blurtbox">
                <!--  most recent blurt tab-->
                <h3> "{pv1::Blurt}"</h3>
                <p> Blurted from {pv1::Location} at {pv1::Date}</p>
                <p>Empathize or Advise about {pv1::Name}'s Blurt #<a href="detailblurt.php?blurtid={pv1::Id_blurt}"> {pv1::Id_blurt}</a></a></p>
               <span id="{pv1::Id_blurt}" class="ratingContainer">
                <span class="ratingButton"></span>
                <span class="ratingButton"></span>
                <span class="ratingButton"></span>
                <span class="ratingButton"></span>
                <span class="ratingButton"></span>
                <span class="ratingRatedMsg">Thank You! Your tears have been tallied.</span>
                <input type="text" id="ratingValue" name="dynamic_rate" value="{pv1::average_r}"/>
            </span>
            <script type="text/javascript">
                // overview of available options and their values:
                // http://labs.adobe.com/technologies/spry/articles/rating_overview/index.html
                var rating1 = new Spry.Widget.Rating("{pv1::Id_blurt}", {ratingValueElement:'ratingValue', afterRating:'serverValue', saveUrl: 'save.php?id={pv1::Id_blurt}&val=@@ratingValue@@'});
            </script>
                 <br/>
               </div>
              </div>
    Ok, it registers the right vote in the database with the right blurt id each time. But I am having two problems so far:
    One, even though {pv1::average_r} returns the correct average through xml, it doesn't show the initial rating value for each of the repeating blurts. It seems to show the first one correct, and then just repeat that same value to the other ones that follow. I just dont understand since it can get the correct server value right after you vote (afterRating:'serverValue), that I can't manipulate spryrating.js in some way that I could just replace 'ratingValue' in ratingValueElement:'ratingValue' with something to give me the initial server value.
    Two: Is even more mysterious to me, if you play around with voting on the site, sometimes you are unable to vote on different blurts. Its weird. It seems like that the javascript is completely off just on those blurts. And sometimes its a whole row, sometimes none. But so far its never a problem on the first tabbed panel (Recent), only on the other three. As far as I know, the coding is exactly the same in each tab's repeating region except for the different xml input.
    And, now on the live server, sometimes the pics of tears used to voting dont show up until you click.
    Any help on those three questions (how to query the fourth panel, how to show the initial server value, and the glitches with voting) would be greatly appreciated!! I looked pretty hard on adobe forums and other sites, and didnt see much on how to really use the spry rating widget with php and xml.
    Thanks!!

    Update:
    Ok, the first query on the Recent tab doesnt work for me because it wont show unless its already voted, and since these are supposed to be new blurts, that kind of breaks the whole site:
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt Group By Id_blurt ORDER BY Blurt.`Date` DESC";
    So I replaced it with what I originally had.
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date FROM Blurt ORDER BY Blurt.`Date` DESC";
    But this doesn't provide me with the initial average rating:(

  • Submitting a Form in a Spry Tabbed Region

    I have a spry tabbed region with 6 tabs.
    I have constructed a menu which targets and opens the specific tab using the ?tab=4 type notation.  I have also created links between tabs using the same notation.  All works fine.
    I have a form in one tab which, when I submit it, I want to return to the same tab.  However when I use the notation <form action="index.php?tab=4" > the page just reloads on the first tab, stripping off the ?tab=4 part of the url. I have searched the forums but can't find any reference to how to target a specific tab when submitting a form.
    Any help much appreciated.
    Thanks
    John

    Hi
    Thanks for your patience.
    Because there are 8 tabs on this page there is a lot of code, much of it irrelevant, so I have copied below the chunks which relate to this part of the page.
    When the form is submitted the data being returned from the database is correct and is loaded into the page. It is just that the page loads the first tab and you then have to click on the 'Results' tab to see the data which has been returned.
    Ok, from the top of the page the php code which filters the recordset is as follows;
    <?php
    if (!function_exists("GetSQLValueString")) {
    function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
      if (PHP_VERSION < 6) {
        $theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
      $theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);
      switch ($theType) {
        case "text":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;   
        case "long":
        case "int":
          $theValue = ($theValue != "") ? intval($theValue) : "NULL";
          break;
        case "double":
          $theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
          break;
        case "date":
          $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
          break;
        case "defined":
          $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
          break;
      return $theValue;
    // recordset for results
    $var1_rsCompResults = "-1";
    if (isset($_GET["event_ID"])) {
      $var1_rsCompResults = $_GET["event_ID"];
    $var2_rsCompResults = "-1";
    if (isset($_GET["age_group"])) {
      $var2_rsCompResults = $_GET["age_group"];
    $var3_rsCompResults = "-1";
    if (isset($_GET["gender"])) {
      $var3_rsCompResults = $_GET["gender"];
    mysql_select_db($database_connPublic, $connPublic);
    $query_rsCompResults = sprintf("SELECT tblResults.result_ID, DATE_FORMAT(tblEvents.event_start_date, '%%Y') AS year, tblResults.event_ID, tblEvents.event_name, tblResults.age_group, tblResults.points, tblIndividuals.forename, tblIndividuals.surname, tblIndividuals.sex FROM tblEvents INNER JOIN tblResults ON tblEvents.event_id = tblResults.event_ID INNER JOIN tblIndividuals ON tblResults.individual_ID = tblIndividuals.individual_id WHERE tblResults.event_ID = %s AND age_group = %s AND sex = %s ORDER BY tblResults.points", GetSQLValueString($var1_rsCompResults, "int"),GetSQLValueString($var2_rsCompResults, "text"),GetSQLValueString($var3_rsCompResults, "text"));
    $rsCompResults = mysql_query($query_rsCompResults, $connPublic) or die(mysql_error());
    $row_rsCompResults = mysql_fetch_assoc($rsCompResults);
    $totalRows_rsCompResults = mysql_num_rows($rsCompResults);
    ?>
    then the links to the Spry Assets and the  js which creates the datasets is as follows;
    <script src="../SpryAssets/SpryTabbedPanels.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryURLUtils.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryData.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryDataExtensions.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryHTMLDataSet.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryNestedXMLDataSet.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryXML.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryTabbedPanels.js" type="text/javascript"></script>
    <script src="../SpryAssets/SpryPagedView.js" type="text/javascript"></script>
    <script src="../SpryAssets/xpath.js" type="text/javascript"></script>
    <script type="text/javascript">
    var dsYears = new Spry.Data.XMLDataSet("competitions_year_data_xml.php", "root/row");
    var dsCompetitions = new Spry.Data.XMLDataSet("calendar_competitions_data_xml.php", "root/row[year = '{dsYears::year}']");
    var dsAgeGroups = new Spry.Data.XMLDataSet("competitions_age_group_data_xml.php", "root/row[event_ID = '{dsCompetitions::event_ID}']");
    var dsGender = new Spry.Data.XMLDataSet("competitions_sex_data_xml.php", "root/row[age_group = '{dsAgeGroups::age_group}']");
    </script>
    Then the html which creates the tabbed region is as follows;
                      <div id="TabbedPanels1" class="TabbedPanels">
                          <ul class="TabbedPanelsTabGroup">
                            <li class="TabbedPanelsTabLeft" tabindex="0">News</li>
                            <li class="TabbedPanelsTab" tabindex="1">Calendar</li>
                            <li class="TabbedPanelsTab" tabindex="2">Rules</li>
                            <li class="TabbedPanelsTab" tabindex="3">Competition Entries</li>
                            <li class="TabbedPanelsTab" tabindex="4">Results</li>
                            <li class="TabbedPanelsTab" tabindex="5">Rankings</li>
                            <li class="TabbedPanelsTab" tabindex="6">Contacts</li>
                            <li class="TabbedPanelsTabRight" tabindex="7">FAQ</li>
                          </ul>
                          <div class="TabbedPanelsContentGroup">
    Then the form which includes the four select statements is as follows;
    <div class="TabbedPanelsContent" id ="results_data">
                   <h3>Results</h3>
    <form name="selectForm" action="index.php?tab=4&" method="get">
            Year:
    <span spry:region="dsYears" id="yearSelector">
            <select spry:repeatchildren="dsYears" spry:choose="spry:choose" name="year" onchange="dsYears.setCurrentRowNumber(this.selectedIndex);">
                <option value="{year}" spry:when="{ds_CurrentRowID} == {ds_RowID}" selected="selected">{year}</option>
                <option value="{year}" spry:default="spry:default" >{year}</option>
            </select>
    </span>
            Event:
    <span spry:region="dsCompetitions" id="eventSelector">
            <select spry:repeatchildren="dsCompetitions" name="event_ID" onchange="dsCompetitions.setCurrentRowNumber(this.selectedIndex);">
                <option value="{event_ID}">{event_name}</option>
            </select>
    </span>
            Age Groups:
    <span spry:region="dsAgeGroups" id="agegroupSelector">
            <select spry:repeatchildren="dsAgeGroups" name="age_group" onchange="dsAgeGroups.setCurrentRowNumber(this.selectedIndex);">
                <option value="{age_group}">{age_group}</option>
            </select>
    </span>
            Gender:
    <span spry:region="dsGender" id="genderSelector">
            <select spry:repeatchildren="dsGender" name="gender">
                <option value="{sex}">{sex}</option>
            </select>
    </span>
    <input type="submit" value="Submit" />
    </form>
    <?php if ($totalRows_rsCompResults > 0) { // Show if recordset not empty ?>
      <div id="result_ID" name="result_ID">
        <table>
          <tr>
            <th>Athlete Name</th>
            <th>Event</th>
            <th>Score</th>
          </tr>
          <?php do { ?>
            <tr>
              <td><?php echo $row_rsCompResults['forename']; ?> <?php echo $row_rsCompResults['surname']; ?></td>
              <td><?php echo $row_rsCompResults['event_name']; ?></td>
              <td><?php echo $row_rsCompResults['points']; ?></td>
            </tr>
            <?php } while ($row_rsCompResults = mysql_fetch_assoc($rsCompResults)); ?>
        </table>
      </div>
      <?php } // Show if recordset not empty ?>
           </div> <!-- end of TabbedPanelsContent div Results -->
    Then at the end of the page is this code;
    <script type="text/javascript">
    var TabbedPanels1 = new Spry.Widget.TabbedPanels("TabbedPanels1", {defaultTab: params.tab ? params.tab : 0});
    </script>
    </body>
    </html>
    <?php
    mysql_free_result($rsCompResults);
    ?> 

  • Help with Spry Detail Regions, XML Data Sets, for IMG gallery

    Hello,
    I'm working on a site for a friend of mine, a photo gallery. You can see the gallery here, it's a temporary one I'm working on
    http://www.emiliajozefa.com/a_index.html
    Here are some important parts of my code:
    //initially load these data sets. the function will be called by the links to update components later<script type="text/javascript">
         var intNumPhoto = 0;
         dsGallery = new Spry.Data.XMLDataSet("photofile.xml", "galleries/ride/photo");
         dsNav = new Spry.Data.XMLDataSet("photofile.xml", "galleries/ride");
         function updateSpryComponents(galleryDir){
              alert("updating spry components for " + galleryDir);
              intNumPhoto = 0;
              dsGallery = Spry.Data.XMLDataSet("photofile.xml", "galleries/" + galleryDir + "/photo");
              dsNav = Spry.Data.XMLDataSet("photofile.xml", "galleries/" + galleryDir);
              dsGallery.setCurrentRow(intNumPhoto);
              //document.getElementById('nav').innerHTML='<H1>'+enlarge.inp.value+'</H1>';
              document.getElementById('nav').innerHTML=
              "<span spry:detailregion = 'dsGallery'>
             <a href = 'javascript:' onclick = 'if(intNumPhoto > 0){intNumPhoto -= 1}; dsGallery.setCurrentRow(intNumPhoto);'>&lt;</a> {@id} / </span>
             <span spry:detailregion = 'dsNav'>{@numPhotos}
             <a href = 'javascript:' onclick = 'if(intNumPhoto < ({@numPhotos} - 1)){intNumPhoto += 1; }; dsGallery.setCurrentRow(intNumPhoto);'>&gt;</a>
             </span>";
    </script> <--- later ----><!-- SIDEBAR NAV. When link i clicked, set DataSet to the location of the new gallery -->
         <div id = "sideBarNav">
             <a href = "javascript:" onclick ='updateSpryComponents('ride');">Tannersville</a>
                <br />
              <a href = "javascript:" onclick = "updateSpryComponents('dive');">Dive</a>
            <br />
              <a href = "javascript:" onclick = "updateSpryComponents('poland');">Poland</a>
            <br />
              <a href = "javascript:" onclick = "updateSpryComponents('alaska');">Alaska</a>
        </div>
    </div>
    <div id = "content2">
         <!-- PHOTO CONTAINER I think I somehow need to refresh this section of the code to reload new data-->
         <div id = "fotoContainer" spry:detailregion="dsGallery"><img src = "photos/{@path}" width = "{@width}" height = "{@height}"/></div>
         <!-- IMAGE NAVIGATION -->
         <div id = "nav">       
             <span spry:detailregion = "dsGallery" id = "galSpan">
             <a href = "javascript:" onclick = "if(intNumPhoto > 0){intNumPhoto -= 1}; dsGallery.setCurrentRow(intNumPhoto);">&lt;</a> {@id} / </span>
             <span spry:detailregion = "dsNav" id = "navSpan">{@numPhotos}
             <a href = "javascript:" onclick = "if(intNumPhoto < ({@numPhotos} - 1)){intNumPhoto += 1; }; dsGallery.setCurrentRow(intNumPhoto);">&gt;</a>
             </span>
         </div>
    You could view source there to get the code. Here is what I believe is my problem
    I'm trying to automate the site so that when you click on one of the links on the left, without refreshing the page, the paths to the galleries xml file changes, and the spry Detail Regions (1 for the images, 1 for the navigation - left and right arrows). I think the problem is that once the link changes the set and calls my updateSpryComponenets() function, the detail regions need to be refreshed. I'm currently trying to solve this by dynamically rewriting the HTML thru .innterHTML, everytime I call updateSpryComponents().There may also be a problem in the Javascript function updateSpryControllers because if I put the alert after the spry calls, I never get the alert
    Thanks in advance for any help!

    Update:
    Ok, the first query on the Recent tab doesnt work for me because it wont show unless its already voted, and since these are supposed to be new blurts, that kind of breaks the whole site:
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt Group By Id_blurt ORDER BY Blurt.`Date` DESC";
    So I replaced it with what I originally had.
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date FROM Blurt ORDER BY Blurt.`Date` DESC";
    But this doesn't provide me with the initial average rating:(

  • Help With Spry Repeat Regions

    Hello everyone,
    I've recently started using Spry for a project I've been
    asked to work on and I've run in to a few issues since my spec
    changed on me today. So any help or advice anyone has is very much
    welcome as I'm very much out my comfort zone at the moment.
    Original Spec
    The idea originally was to have a drop down of roles which
    was created from the role tag within a xml file which I was able to
    do as you can see below in the attached code. Once the user had
    picked a role it would then
    ds2.setCurrentRowNumber(this.selectedIndex) and this would trigger
    the spry detail region I have to populate the fields I setup to get
    out of the xml the role, process and info.
    At the time I was told a role would only appear once in the
    file but this is now not the case :(
    My problem / New Spec
    Unfortunately with the xml now having a role more then once
    I've been asked to include a dynamic region which will display the
    process and info fields from other records which have this role
    name. Which is the bit I'm having problems with. I've been playing
    with creating a spry:repeat for each field and then using
    Spry:if="'{Role}'.search(^/myVar/) != -1; but I've had no luck
    getting a value into a variable and I'm lack of experience is
    running out of ideas.
    Hope I've made sense this is my first time using spry and
    JavaScript, so any help is greatly welcome.
    Thanks Nick.
    Example of the XML file - Please note this is very much a cut
    down version.

    tried changing the Region HTML table cell attributes to width:75pct, but this has no effect.Unsurprisingly. Use a valid CSS length specification.

  • Displaying rendered HTML text in spry detail region

    Hi,
    I have just started to play around with DW CS3 & spry and
    love them!
    I have a Master/Detail spry going from my database, but am
    having a problem displaying the detail the way I need it. The mySQL
    field is a BLOB for some HTML formatted text (I get the text
    elsewhere using a Xinha textarea edit widget and load the the
    formatted HTML text into my db). For example, my string is
    "<h2>this test</h2><strong>xyz</strong>"
    which is loaded into my db. I am using the dreamweaver ADDT export
    XML functionality to generate my spry master/detail region.
    My detail region is displaying the correct html associated
    with the selected master table entry, but it's with the HTML tags,
    not rendered as HTML (I don't want to see
    <h2>title</h2>; I'd like to see title with <H2>
    formatting).
    It's much like what I think a RSS feed would be, but can't
    find a way just to get the html to render because I don't have the
    files externally to source an iframe or anything. (I tried a XLS
    fragment transformation, just putting the detail record field that
    I want in an XLS file, but that didn't do anything).
    Any kind of guidance, hint, point and laugh but then tell me,
    would be greatly appreciated. I also posted at first at ADDT and
    then General Dreamweaver because I didn't locate this forum in the
    Forum topic list, so when I did find this I thought this is
    obviously where I should have first posted - sorry if anyone has
    also been surfing around. Thanks so much so any info.

    Hi Don,
    Thanks so much for responding. I actually did do that, but it
    seems like I might be doing it in the wrong place. I tried it in
    the .js that I have in my header:
    var dsList = new Spry.Data.XMLDataSet("./export.php",
    "theSpecials/special",{sortOnLoad:"rating",sortOrderOnLoad:"ascending",distinctOnLoad:tru e});
    dsList.setColumnType("detail", "html");
    which didn't do it. I also tried it right in my detail
    display area:
    <div style="overflow:hidden; width: 400px;"
    spry:detailregion="dsList">
    <div> <!-- nested div for spry effect -->
    <div id="detailDisplay" style="width:380px; "> <!--
    spry:content="{detail}"> -->
    <script
    type="text/javascript">dsList.setColumnType("detail","html");</script>{dsList::detail}
    <!-- echo '{dsList::detail}' ; ?> -->
    </div> <!-- detailDisplay -->
    </div> <!-- outter div for spry effect -->
    <!-- spry detail region -->
    </div>
    Excuse the inline ugliness, will clean it up when it's
    functional. But that doesn't seem to do it either. I am storing
    that particular field as a blob in the mysql database, but I
    already tried making that a VARCHAR which had no effect either.
    Thanks so much for for the suggestion! Any other gems that I
    can try?
    Liz

  • Usin Spry$$ in spry:repeat regions

    Hi,
    I'm not sure whats happening here but i'll try to be
    detailed.
    I am using spry to make a master page set.
    on a region i have
    quote:
    var observer = { onPostUpdate: function(notifier, data) { var
    r = Spry.$$(".changeStatusLink").addEventListener("click",
    changeStatus, true); } };
    where the element selector is
    quote:
    <td align="center" valign="middle" nowrap="nowrap"
    spry:setrow="ds1 {ds_rowID}">[EDIT] | [<a
    id="statusLink{ds_RowID}" class="changeStatusLink">CHANGE
    STATUS</a>] | [DELETE]</td>
    in a
    spry:repeat region
    Now on a "click" the selector is able to trigger the
    changeStatus function....but for some reason
    only the first row's {ds_RowID} of the
    spry:repeat is being captured when the function
    "changeStatus"
    is
    quote:
    function changeStatus(e){
    var row = ds1.getCurrentRow();
    var id = row['@id'];
    alert(id);
    is it the fact that because the "class" is being repeated it
    is not picking up the actual "element" that triggered the event? or
    is there something wrong with the ds1.getCurrentRow?Text

    the spry:repeat IS on the
    <tr>
    I don't have a URL
    but the code is...
    quote:
    <!--
    var ds1 = new Spry.Data.XMLDataSet("get_docs.php",
    "documents/doc",{sortOnLoad:"@section",sortOrderOnLoad:"ascending",useCache:false});
    ds1.setColumnType("@id", "number");
    function MySuccessCallback(req)
    var state = req.xhRequest.responseText;
    if(state == 1){
    ds1.setDataFromArray([req.userData]);
    }else if(state == 2){
    }else{
    function MyErrorCallback(req)
    // Throw an alert with the message that was
    // passed to us via the userData.
    alert("ERROR: " + req.userData.msg);
    function changeStatus(e){
    alert(e.target);
    var row = ds1.getCurrentRow();
    var id = row['@id'];
    alert(id);
    var req = Spry.Utils.loadURL("POST", "set_status.php", true,
    MySuccessCallback, { postData: "docid="+id+"&action=status",
    headers: { "Content-Type": "application/x-www-form-urlencoded;
    charset=UTF-8" }, errorCallback: MyErrorCallback, userData: row })
    var observer = { onPostUpdate: function(notifier, data) { var
    r = Spry.$$(".changeStatusLink").addEventListener("click",
    changeStatus, true); } };
    Spry.Data.Region.addObserver("documentList", observer);
    Spry.Utils.addEventListener(Spry.$$(".changeStatusLink"),"click",changeStatus,true);
    //-->

  • Spry Validation in Spry Detail Region

    I am trying to pre-populate an "update" data form using a
    spry detail region. Basically a list of users is displayed on the
    left, and the detail in a tab on the right. A second "edit" tab
    displays a form that is populated with data from the spry dataset
    using a detail region (just as the first detail tab). However, the
    spry validations within the detail region do not work.
    Download
    this zip.
    Thanks for looking.

    Hi jmortimer,
    What you need to do is trigger the constructors for your
    validation widgets every time the region updates. To do this, you
    need to either move the constructor calls into your region, *or*
    call the constructors from an onPostUpdate observer on your region.
    To see an example of this, look here:
    http://labs.adobe.com/technologies/spry/samples/accordion/AccordionSample2.html
    Just a note ... don't move the constructor for your tabbed
    panel into the region. Leave it where it is today.
    --== Kin ==--

  • Spry Validation in a Spry Detail Region

    am trying to pre-populate an "update" data form using a spry
    detail region. Basically a list of users is displayed on the left,
    and the detail in a tab on the right. A second "edit" tab displays
    a form that is populated with data from the spry dataset using a
    detail region (just as the first detail tab). However, the spry
    validations within the detail region do not work.
    Download
    this zip.
    Thanks for any help.

    Hi jmortimer,
    What you need to do is trigger the constructors for your
    validation widgets every time the region updates. To do this, you
    need to either move the constructor calls into your region, *or*
    call the constructors from an onPostUpdate observer on your region.
    To see an example of this, look here:
    http://labs.adobe.com/technologies/spry/samples/accordion/AccordionSample2.html
    Just a note ... don't move the constructor for your tabbed
    panel into the region. Leave it where it is today.
    --== Kin ==--

  • [CS3]Implementing collapsing/expander region in CS3

    Hello all,
    I'm trying to add a collapsing/expander region in one of my palette/dialog in a plugin, a sample of that was implemented in 'Effects' palette in CS3, Can someone give me some direction/ code snippet to implement that?
    Thanks for any help,
    Mor

    I am working on one now (must be a fashion thing).<br /><br />the key calls are:<br /><br />IControlView's MoveTo for the widgets <br /><br />and  <br /><br />InterfacePtr<IControlView> cv(fPanel, UseDefaultIID());<br />cv->Resize(newDimensions);<br /><br />to resize the panel.<br /><br />plus you need to calc the new heights and  for top left's for the widget, once you picked up the click to do expand or shrink.

  • Has anyone implemented CKEditor in a Spry Data Region?

    I have been trying to implement an HTML editor in a Spry Data Region without success.
    CKEditor is a follow up from FCKEditor and is supposed to slot into Ajax applications.
    The website is here: http://docs.fckeditor.net/CKEditor_3.x/Developers_Guide.
    Any help will be greatly appreciated.
    Ben

    Just make sure you call the
    CKEDITOR.replace('editor1'); // editor1 being the id of your text area
    everytime the region gets updated. The best way to do this is add a Spry region observer, that calls that line of code during the onPostUpdate observer.
    Read more about the observers here:
    http://labs.adobe.com/technologies/spry/articles/data_set_overview/index.html

  • Split Spry.Data and Spry.Data.Region from SpryData.js?

    I don't like Spry.Data.Region or anything like Spry.*.Region because it make hard to customize using javascript.
    But Spry.Data with Observer / Notify feature is great one. In fact, using SpryData.js, I can write my own "render html object" easier.
    SrpyData.js is big (127KB) even when compressed, it is still 65KB. That why, needed split Spry.Data and Spry.Data.Region from SpryData.js so who want to use Spry.Data only like me will get smaller trafic.
    I've tried remove all Spry.Data.Region content in SpryData.js. Surprise, some in Spry.Data call to Spry.Data.Region >>> Design have problem.
    Anyone can help splitting them?

    Found this in the archives:
    <div spry:if="{ds_RowCount} == 0" class="trigger" style="display:none"></div>
    Basically a hack to point the tooltip to a hidden div so no errors are thrown.

Maybe you are looking for