collapse a panel through javascript

  1. #1

    collapse a panel through javascript

    Hi everyone, is it possible to collapse a panel through javascript ?
    I can't find the way to do this.

    Thanks a lot!

    1. call a javascript function name test()
    <li id="itemActivities"><a href="#" onclick="test();">Activities</a></li>
    2. test function
    <script type="text/javascript">
            function test()
        {
            panelName.Collapsed = "true";
        }
        </script>
  2. #2
    Hello,

    You can call the .collapse() and .expand() functions from JavaScript.

    Example

    panelName.collapse();
    The functions are listed in the client-side documentation:

    http://docs.sencha.com/extjs/3.4.0/#...ethod-collapse

    Hope this helps.
    Geoffrey McGill
    Founder
  3. #3

    Thanks!

    Quote Originally Posted by geoffrey.mcgill View Post
    Hello,

    You can call the .collapse() and .expand() functions from JavaScript.

    Example

    panelName.collapse();
    The functions are listed in the client-side documentation:

    http://docs.sencha.com/extjs/3.4.0/#...ethod-collapse

    Hope this helps.


    Thanks, that's exactly what I'm trying to do.

Similar Threads

  1. Panel in Viewport can't Collapse,PLZ Help!
    By goga21cn in forum 2.x Help
    Replies: 5
    Last Post: Apr 08, 2013, 7:56 AM
  2. Replies: 1
    Last Post: Dec 12, 2011, 12:50 AM
  3. [CLOSED] [1.0] Panel collapse from javascript giving error
    By vedagopal2004 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Mar 08, 2010, 6:23 AM
  4. Replies: 4
    Last Post: Aug 19, 2009, 2:01 PM
  5. West panel does not collapse
    By sz_146 in forum 1.x Help
    Replies: 3
    Last Post: Jan 30, 2009, 12:13 PM

Posting Permissions