Opening first tab of jquery accordion when page loads

Hello, I am wondering how I would make the first tab of my accordion to open when the page loads. It is a custom accordion and therefore it is hard to find the answer online.
I want this to be specific to a certain page if possible rather than universal across the site.
Here is the HTML:
<div id="st-accordion" class="st-accordion">
                    <ul>
                        <li>
                            <a href="#">Lorem ipsum<span class="st-arrow">Open or Close</span></a>
                            <div class="st-content">
                                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque consequat auctor ante, sodales pretium felis auctor in. Aenean tempor, orci vel vestibulum lobortis, justo augue laoreet turpis, id consectetur dolor arcu sed arcu. Sed id dolor tellus. Nulla eros risus, sollicitudin in ultricies ac, tincidunt et nisl. Nam ac consectetur est. Morbi pretium libero in lacus semper ultricies. Vestibulum in nibh a ligula malesuada posuere ac vel lorem. Duis varius scelerisque vehicula. Maecenas convallis tellus in tellus facilisis eget sollicitudin est lacinia. Ut quam tortor, pretium non lacinia sit amet, iaculis ac ipsum. Donec quis libero accumsan felis fringilla pulvinar eget in leo.</p>
                            </div>
                        </li>
                        <li>
                            <a href="#">Lorem ipsum<span class="st-arrow">Open or Close</span></a>
                            <div class="st-content">
                                <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque consequat auctor ante, sodales pretium felis auctor in. Aenean tempor, orci vel vestibulum lobortis, justo augue laoreet turpis, id consectetur dolor arcu sed arcu. Sed id dolor tellus. Nulla eros risus, sollicitudin in ultricies ac, tincidunt et nisl. Nam ac consectetur est. Morbi pretium libero in lacus semper ultricies. Vestibulum in nibh a ligula malesuada posuere ac vel lorem. Duis varius scelerisque vehicula. Maecenas convallis tellus in tellus facilisis eget sollicitudin est lacinia. Ut quam tortor, pretium non lacinia sit amet, iaculis ac ipsum. Donec quis libero accumsan felis fringilla pulvinar eget in leo </p> 
                            </div>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
        <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script>
        <script type="text/javascript">
            $(function() {
                                        $('#st-accordion').accordion({
                                                  oneOpenedItem          : true
        </script>
                    <script type="text/javascript" src="js/jquery.easing.1.3.js"></script>
        <script type="text/javascript" src="js/jquery.accordion.js"></script>
            </div>
And the CSS:
.st-accordion{
    width:100%;
    min-width:270px;
    margin: 0 auto;
}.st-accordion ul li{
    height: 100px;
    border-bottom: 1px solid #c7deef;
    border-top:1px solid #fff;
    overflow: hidden;
.st-accordion ul li:first-child{
    border-top:none;
.st-accordion ul li > a{
    font-family: 'Josefin Slab',Georgia, serif;
    text-shadow: 1px 1px 1px #fff;
    font-size: 22px;
    display: block;
    position: relative;
    line-height: 100px;
    outline:none;
    -webkit-transition:  color 0.2s ease-in-out;
    -moz-transition:  color 0.2s ease-in-out;
    -o-transition:  color 0.2s ease-in-out;
    -ms-transition:  color 0.2s ease-in-out;
    transition:  color 0.2s ease-in-out;
.st-accordion ul li > a:hover{
    color: #1693eb;
.st-accordion ul li > a span{
    background: transparent url(../images/down.png) no-repeat center center;
    text-indent:-9000px;
    width: 26px;
    height: 14px;
    position: absolute;
    top: 50%;
    right: -26px;
    margin-top: -7px;
    opacity:0;
    -webkit-transition:  all 0.2s ease-in-out;
    -moz-transition:  all 0.2s ease-in-out;
    -o-transition:  all 0.2s ease-in-out;
    -ms-transition:  all 0.2s ease-in-out;
    transition:  all 0.2s ease-in-out;
.st-accordion ul li > a:hover span{
    opacity:1;
    right: 10px;
.st-accordion ul li.st-open > a{
    color: #1693eb;
.st-accordion ul li.st-open > a span{
    -webkit-transform:rotate(180deg);
    -moz-transform:rotate(180deg);
    transform:rotate(180deg);
    right:10px;
    opacity:1;
.st-content{
    padding: 5px 0px 30px 0px;
.st-content p{
    font-size:  16px;
    font-family:  Georgia, serif;
    font-style: italic;
    line-height:  28px;
    padding: 0px 4px 15px 4px;
.st-content img{
    width:125px;
    border-right:1px solid #fff;
    border-bottom:1px solid #fff;
@media screen and (max-width: 320px){
    .st-accordion ul li > a{
        font-size:14px;
@media screen and (max-width: 800px){
    .st-accordion ul li > a{
        font-size:16px;
You can find the page at http://bit.ly/Zrpt1s
Any help is grately appreciated thanks!

Try
$(function() {
    $('#st-accordion').accordion({
        oneOpenedItem    : true,
       open: 0

Similar Messages

  • After upgrading iPad 2 to iOS 7 , cannot open new tabs in safari . When pushing on " " , Safari close the application .

    After upgrading iPad 2 to iOS 7 , cannot open new tabs in safari . When pushing on " " , Safari close the application .

    Try a Restart. 
    Press and hold the Sleep/Wake button for a few seconds until the red "slide to power off" slider appears, and then slide the slider. Press and hold the Sleep/Wake button until the Apple logo appears.
     Resetting your settings
    You can also try resetting all settings. Settings>General>Reset>Reset All Settings. You will have to enter all of your device settings again.... All of the settings in the settings app will have to be re-entered. You won't lose any data, but it takes time to enter all of the settings again.
    Resetting your device
    Press and hold the Sleep/Wake button and the Home button together for at least ten seconds, until the Apple logo appears. Apple recommends this only if you are unable to restart it.
    Or if this doesn't work and nobody else on the blog doesn't have a better idea you can contact Apple. 
    Here is a link to their contacts with most of the information below. 
    http://www.apple.com/contact/

  • I just started Firefox 3.6.13 this morning and it open 27 tabs of the Firefox Support page. Can anyone tell me why?

    I just started Firefox 3.6.13 this morning and it open 27 tabs of the Firefox Support page. Can anyone tell me why?

    Did you press the F1 key?<br />
    Did it only happen once?
    See [[How to set the home page]] - Firefox supports multiple home pages separated by '|' symbols
    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]
    * [[Troubleshooting plugins]]

  • Inputtext component refreshes and the entered data is vanishes only happen when page loads first time

    Hi,
    Am using 11.1.1.5 adf jdev.
    I got unique issue , i have couple of jsff seach pages . In jsff , i have user enterable inputtext box ,Issue is when user enters data for first time . the component refreshes and the entered data is vanishes .
    But it happen for the first time when page loads, There is no partial triggers on dat input text box.

    Hi John,
    My page is not a part of a task flow. The whole app is an Admin app comprising of multiple individual pages navigated using Menu.
    I have tried to run this page individually on my local machine as well as when deployed on the WLS server. The behavior is the same.
    Kindly advice,
    Thanks,
    Ram

  • Pagination - JavaScipt in "Execute when Page Loads" stop working

    I'm using APEX 4.0.
    I have a standard report region on a page. In the page's JavaScript - Execute When Page Loads area, I put some javascript code there to initialize hover event handlers for dropdown menus inside the report. It works fine when the report is genarated.
    But it stop working when a pagination performed. For example, after clicked 'next" or any number form the pagination dropdown list.
    Please advice how to fix it. Thanks.
    Shiofan

    Hi, Peter:
    Thanks for the quick reply. That is appreciated.
    My code involves only CSS and JQuery.
    I have found out the reason. It is because "Enable Partial Page Refresh" was set to Yes. ( that is the default by APEX, isn't it? ). After I reset it to No, the dropdown menu does work fine after pagination.
    I don't know how APEX pagination work together with report attribute "Enable Partial Page Refresh". To me, no matter what, the style sheet, the JavaScript put in page template/page header should always be included since they are common to the page. Can we say this is an APEX bug need to be fixed?
    Thanks again.
    Shiofan

  • Dynamically displaying ADF rich components in UI, when page loads

    Hi All
    Could you please tell me how to display ADF 11g rich components in UI programmatically from managed bean, when page loads.
    I tried to call onPageLoad() from pagePhaseListener, however no idea how to set the components to the UI from onPageLoad() method. Please someone help me.
    Regards
    Venkat.S

    Thanks for your response Abhijit.
    However in the given video, ADF components are displaying only after clicking the button. But i need to know how to display those components dynamically when page loads(i.e, i wont be clicking any button). While page loads those components should display dynamically.

  • Javascript in 'Execute when page loads', not working when paging results grid

    I have some Javascript in an Apex page, running in 'Execute when page loads'. It does some stuff to a results grid. It works fine on page load, but then doesn't run when I page through, or sort the grid. I presume this is because the grid is being sorted / paged using Ajax, which means the page isn't being fully loaded.
    Is there anywhere else I can put the code so it gets applied to the grid on sorts and paging?

    Thanks, works perfectly! I used the After Refresh and just selected the region I wanted to trigger the Javascript, and it works great. As you say the scope needs to be Dynamic.
    For anyone else reading this, something which caught me out was that my reports region was using the No Template setting, and the Dynamic Action didn't work, as it requires you to use a template which contains #REGION_STATIC_ID# - which is used by the dynamic action to identify the region. Once I switched to using a template, it worked fine.

  • I can set my default home page (when Firefox starts) but if I open subsequent tabs I get a blank page. How do I set my default home page for all tabs.

    I set my default home page to AltaVista.com. This page comes up as expected when I start Firefox. However if I open a new tab I get a blank page. How to I setup Firefox to use my default web page for all subsequent tabs. This was an easy process in IE

    Sounds like you want the New Tab Homage extension.
    https://addons.mozilla.org/en-US/firefox/addon/777/
    For more info about extensions, see [[Using extensions with Firefox]]

  • Opening Multiple Tabs on IE Start-Up Page.

    Hi,
    We've a differrent requirement like, when User open IE, first tab should be default company home page (User shouldn't have access to change first tab home page) then the remaining
    tabs can be set by User’s choice.  Do we've such securities in internet explorer?

    Start>Run>GPEdit.msc
    You can configure the user and machine Start Page settings and disable users changing the Homepage settings with Internet Options.
    Rob^_^

  • How to open List when Page loads in SharePoint Hosted App?

    I  want to create an app same like InstantPracticeManager by InstantQuick.
    Now I want to know that in a SharePoint Hosted App How can I show the Whole List in a page. 
    Here I have added one image:
    Here there is one list and there are 4 views of that list.
    Now the App will be like when I load the page It will show like the image above. Now how can we show the list like this in sharepoint hosted app?
    I want the same scenario which is shown in the following blogs:
    http://sp2013.blogspot.in/2012/08/use-list-view-in-sharepoint-2013-apps.html
    and
    http://www.sharepointnutsandbolts.com/2013/08/working-with-web-parts-within.html
    where they add a list to an app
    Can any one suggest me the idea? I am bit confused.
    thanks in advance.

    Hi,
    According to your post, my understanding is that you want to show the different list view in a page in SharePoint Hosted App.
    We can use jQuery and cross-domain library to achieve it.
    The following articles for your reference:
    Adding a Tabbed View to A Web Part Page Using jQueryUI
    http://sympmarc.com/2011/11/09/adding-a-tabbed-view-to-a-web-part-page-using-jqueryui/
    How to: Access SharePoint 2013 data from apps using the cross-domain library
    http://msdn.microsoft.com/en-us/library/office/fp179927(v=office.15).aspx
    SharePoint 2013: Get list items by using the cross-domain library (JSOM)
    http://code.msdn.microsoft.com/office/SharePoint-2013-Get-items-d48150ae/view/SourceCode#content
    Thanks,
    Dennis Guo
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Dennis Guo
    TechNet Community Support

  • Open specific tab in an accordion

    I have an accordion with 5 tabs. I want to open a specific
    tab depending on which link is clicked on the first tab.
    I have the following, which opens tab 2:
    <a
    href="javascript:acc1.openNextPanel();">{@atitle}</a>
    and I could use openLastPanel() for tab 5, but how do I open
    tabs 3 and 4?
    I have found a query from Auroras giving a function to do
    this, but I would have expected this to be an inbuilt solution -
    has it been incorporated into 1.5?
    Regards
    John

    To answer my own question (partly...), I have added the
    following into my SpryAccordion.js file:
    quote:
    JBB 13/4/07
    Spry.Widget.Accordion.prototype.openPanelNumber =
    function(numbr)
    var indx = numbr - 1 // panel index starts at 0
    var panels = this.getPanels();
    var curPanelIndex = this.getCurrentPanelIndex();
    if( panels && curPanelIndex != indx && indx
    < panels.length && indx >= 0 )
    this.openPanel(panels[indx]);
    -------------------------------------------------------------- END
    Call this from anywhere you like (eg <a
    href="javascript:acc1.openPanelNumber('2');">{@atitle}</a>).
    The number is 'natural' rather than 'logical' - ie the first tab is
    number 1, the second is 2, etc. Quote marks are optional
    (javascript will just cast the string into an integer) and invalid
    values are ignored.
    Regards
    John

  • Displaying "af:panel accordion" dynamically in UI when page loads

    Hi
    My problem is, whenever my homepage loads "af:panel accordian" should display dynamically in UI. Like, if I mention value 4 in manged bean it should display 4 panel accordion in UI when it loads, and if it is 6 then it should display 6 panel accordion in my homepage.
    Please help me in this issue. Looking forward for you response.
    Regards
    Venkat.S

    Hi
    Actually only one panel accordion will be in my UI(sorry for my previous message), but the "af:showdetailitem" under af:panel accordion will differ and the values of this will varies each time when the page loads. So dynamically i should add af:showDetailItem into this af:panelAccordion from manged bean.
    Regards
    Venkat.S

  • The first tab in my browser always shows loading and cannot close it, Why?

    When my browser is open and have multiple tabs open, the first tab has the animated circle that shows that page is loading, and if I try to close that tab it does not close. I have tried to uninstall and reinstall but have not been able to clear this issue up, Please help!

    * "Clear the Cache": Tools > Options > Advanced > Network > Offline Storage (Cache): "Clear Now"
    * "Remove the Cookies" from sites that cause problems: Tools > Options > Privacy > Cookies: "Show Cookies"
    Start Firefox in [[Safe Mode]] to check if one of the add-ons is causing the problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    * Don't make any changes on the Safe mode start window.
    See:
    * [[Troubleshooting extensions and themes]]
    * [[Troubleshooting plugins]]
    If it does work in Safe-mode then disable all extensions and then try to find which is causing it by enabling one at a time until the problem reappears.
    * Use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.
    * Close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

  • How to set Lov item property (Action type,event,parameter etc) in PR when page load

    Hi gurus
    I am new to OAF, First I need to explain my scenerio.
    I need to make some field mandatory or non mandatory based on one LOV item (Pick list or message choice list).
    for this i extended the controler and apply the changes, but in this case what heppen, It will effect only when i open the list (pop list) and click on more (Available in poplist) and it will open a new form and i select value from that form. But when I open the poplist and select the value from the same list rather going to more option (it does not open new form), then there are no effect. I though the issue with refreshing when selecting value from the same list.
    To resolving this issue what i did
    1. go to page == > the same LOV
    2. Change the Client Action properties (
         Action type  = fireAction
         event          = xxevent
        submit = true.
    After doing this when i run the page from my OAF enviroement , every thing is OK. Then I transfer the Controler to Server machine and change the controller and run the same page from the server, it has the same refreshing issue, Then I thought because I did not transfer LOV such properties so this is hepening,
    Now I want to initilize such properties in Page load or what I need to do, Please advise me.
    Regards,
    Haq

    Edward,
    Thank you for the suggestion! It directly lead to my solution wherein I used CASE statements for the column in my Region SELECT such as the following:
    WHEN (:P2_GRADING_METHOD = 'CR/NC' OR scs.scs_pass_audit = 'P') AND GET_GRADE_B93 (sac.stc_final_grade, sac.stc_verified_grade) IS NULL THEN htmldb_item.select_list_from_lov (5, 'Enter Grade', 'GRADE_LOV_CRNC','onBlur="return validate_grade(this,''FW_DATE_'||ROWNUM||''')"','NO',NULL,NULL,'GRADE_'||ROWNUM)
    When the column is NULL, the Select List (LOV) contains the entry 'Enter Grade' and that is the value displayed on page load. I bypass the value 'Enter Grade' during Submit Processing where database updating occurs.
    I did not find the need to enter values for p_null_value and p_null_text since I don't believe that it would cause the 'Enter Grade' value to display on page load for null value columns but rather would enable the user to select 'Enter Grade' from the list and have a specified return value stored in htmldb_item array.
    Again, thank you for the help!

  • Display lov when page load

    hi i have a situation where i what lov to popup when the page load.my situation is i what a lov to popup with , the list of organisation when the page load and when the page load it must display only information for that selected organisation,has anyone done that.am in jdeveloper 11.1.1.6.0

    ok the organisation is selected in the first page which load,i what to select organisation and navigate to next page whare there is only that organisation details
    my first page is below
    <?xml version='1.0' encoding='UTF-8'?>
    <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.1"
              xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
              xmlns:f="http://java.sun.com/jsf/core">
      <af:panelSplitter id="ps1" orientation="vertical" splitterPosition="148">
        <f:facet name="first"/>
        <f:facet name="second">
          <af:panelStretchLayout id="psl1" startWidth="126px" endWidth="124px">
            <f:facet name="bottom"/>
            <f:facet name="center">
              <af:panelStretchLayout id="psl2" endWidth="137px" startWidth="220px">
                <f:facet name="center">
                  <af:panelGroupLayout id="pgl1" layout="vertical" valign="middle"
                                       halign="center">
                    <af:panelStretchLayout id="psl3"
                                           inlineStyle="width:732px; height:340px;"
                                           bottomHeight="100px">
                      <f:facet name="bottom">
                        <af:panelGroupLayout id="pgl2" layout="vertical"
                                             valign="middle" halign="center">
                          <af:panelHeader text="Select Organisation To Update" id="ph1"
                                          inlineStyle="border-style:ridge; border-color:Blue; height:57px;">
                            <f:facet name="context">
                              <af:toolbar id="t1">
                                <af:commandButton text="UpdateOrganisation" id="cb1"
                                                  action="UpdOrg"/>
                              </af:toolbar>
                            </f:facet>
                            <f:facet name="menuBar"/>
                            <f:facet name="toolbar"/>
                            <f:facet name="legend"/>
                            <f:facet name="info"/>
                          </af:panelHeader>
                          <af:panelFormLayout id="pfl1"
                                              inlineStyle="border-color:Blue; border-style:ridge; height:24px; width:720px;">
                            <af:selectOneChoice value="#{bindings.OrgName.inputValue}"
                                                label="OrganisationName"
                                                required="#{bindings.OrgName.hints.mandatory}"
                                                shortDesc="#{bindings.OrgName.hints.tooltip}"
                                                id="soc1">
                              <f:selectItems value="#{bindings.OrgName.items}"
                                             id="si1"/>
                            </af:selectOneChoice>
                          </af:panelFormLayout>
                        </af:panelGroupLayout>
                      </f:facet>
                      <f:facet name="start"/>
                      <f:facet name="end"/>
                      <f:facet name="top"/>
                    </af:panelStretchLayout>
                  </af:panelGroupLayout>
                </f:facet>
                <f:facet name="top"/>
              </af:panelStretchLayout>
            </f:facet>
            <f:facet name="start"/>
            <f:facet name="end"/>
            <f:facet name="top"/>
          </af:panelStretchLayout>
        </f:facet>
      </af:panelSplitter>
    </jsp:root>Edited by: adf009 on 2013/02/06 5:12 PM

Maybe you are looking for

  • Cant get my Outlook contacts and mail set up without crashing...error message is "Apple Outlook DAV config has stopped working"

    When I check the box to add Mail, Contacts, etc to iCloud, it goes through the setup about half way and crashes on the contacts. Error message is: "Apple Outlook DAV Config has stopped working"  Any suggestions? I can't get this stuff set up!  Thank

  • Customer Mss Upload with non ENGLISH language

    Hi, I have a BDC program which uploads customer Address data into the system. Now I have some customer data with non english characters like chinese and Japanese. If I try to upload this data with english language LOGON then data doesnt updates corre

  • Select in DW

    I'm a new DW user. In Golive when you select an image (just clicking on the image) the properties appears in Inspector Palette. But in DW CS3 in need to left click or double click on the image to see properties in Properties Palette. If I only click

  • Nokia 5800 xpress music SW update 50.0.005 !!!!!!!...

    I updated software to 50.0.005 and ever since then my phone is not working.  When I switch it on it stays on the NOKIA start up screen for a while then goes fuzzy and switches off.  Sometimes (meaning about 3 times) it goes on and everything seems fi

  • Dropped my iphone and screen is blank

    I recently dropped my iphone and now the screen won't show up. Anyone have any ideas how to fix it?