Q:

Auto Click with jQuery 1.9 and UI 1.10

I extract some code from my website.And I want to have the Sample Dish  tag been automatically clicked when the page or form loaded.Sample Dish is the last li tag at the most bottom
Can anyone help?
Here is my code :
<div class="form-input-box" id="dishz_input_box">
<select id="field-dishz" name="dishz[]" multiple="multiple" size="8" class="multiselect" data-placeholder="Select Dishz" style="display: none;">
    <option value="9999">Sample Dish</option>
</select>
<div class="ui-multiselect ui-helper-clearfix ui-widget" style="width: 692.3333332538605px;">
    <div class="selected" style="width: 414px;">
        <div class="actions ui-widget-header ui-helper-clearfix"><span class="count">0 items selected</span>
            <a href="#" class="remove-all">Remove all</a>
        </div>
        <ul class="selected connected-list ui-sortable" style="height: 124.33333325386047px;">
            <li class="ui-helper-hidden-accessible"></li>
        </ul>
    </div>
    <div class="available" style="width: 276px;">
        <div class="actions ui-widget-header ui-helper-clearfix">
            <input type="text" class="search empty ui-widget-content ui-corner-all">
                <a href="#" class="add-all">Add all</a>
        </div>
        <ul class="available connected-list" style="height: 124.33333325386047px;">
            <li class="ui-helper-hidden-accessible"></li>
            <li class="ui-state-default ui-element ui-draggable" title="Sample Dish" style="">
                <span class="ui-helper-hidden"></span>Sample Dish<a href="#" class="action">
                <span class="ui-corner-all ui-icon ui-icon-plus"></span></a>
            </li>
        </ul>
    </div>
</div>

A:

On dom ready try
$('#dishz_input_box .available.connected-list > li:last').click()

