$('#default').puifieldset();
<fieldset id="default"> <legend>Title>/legend> Content </fieldset>
Name | Type | Default | Description |
---|---|---|---|
toggleable | Boolean | false | Defines if content of fieldset can be expanded and collapsed. |
toggleDuration | Number/String | normal | Defines the duration of the toggle effect, valid values are "slow", "normal", "fast" or a number in milliseconds. |
collapsed | Boolean | false | Displays the fieldset as collapsed initially. |
Name | Parameters | Description |
---|---|---|
beforeToggle | event: puifieldsetbeforeToggle event | Fired before toggling. |
afterToggle | event: puifieldsetafterToggle event | Fired after toggling. |
$('#default').puifieldset({ afterToggle: function(event) { //... } });
Name | Parameters | Description |
---|---|---|
toggle | - | Toggles content. |
option | name: Name of the option | Returns the value of the option. |
option | name: Name of the option, value: Value of the option | Set the value of the option. |
$('#default').puifieldset('toggle');
<script type="text/javascript"> $(function() { $('#default').puifieldset(); $('#toggle').puifieldset({ toggleable: true }); }); </script>
<fieldset id="default" style="margin-bottom:20px"> <legend>Default</legend> The story begins as Don Vito Corleone, the head of a New York Mafia family, oversees his daughter's wedding. His beloved son Michael has just come home from the war, but does not intend to become part of his father's business. Through Michael's life the nature of the family business becomes clear. The business of the family is just like the head of the family, kind and benevolent to those who give respect, but given to ruthless violence whenever anything stands against the good of the family. </fieldset> <fieldset id="toggle"> <legend>Toggleable</legend> The story begins as Don Vito Corleone, the head of a New York Mafia family, oversees his daughter's wedding. His beloved son Michael has just come home from the war, but does not intend to become part of his father's business. Through Michael's life the nature of the family business becomes clear. The business of the family is just like the head of the family, kind and benevolent to those who give respect, but given to ruthless violence whenever anything stands against the good of the family. </fieldset>