Exemplo n.º 1
0
</div>

<?php 
echo ui_button_pane_init($type = 'single', array('btnExecuteSwitchClass' => array('value' => 'Execute Switch Class Effect')));
echo ui_button_pane_end();
?>

<?php 
echo ui_effects_switch_class('#testSwitchClass', array('listener' => array('selector' => '#btnExecuteSwitchClass', 'event' => 'click'), 'remove' => 'ui-widget-content', 'add' => 'ui-widget-header', 'duration' => 'slow'));
?>

<br><br><br>


<?php 
echo add_jquery_support('document', 'ready', like_function(jquery_toggle_event('#btnAnimate', array(like_function(jquery_execute_effect('.divToAnimate', 'animate', array('options' => array('backgroundColor' => '#aa0000', 'color' => '#fff', 'width' => 500), 'speed' => 1000))), like_function(jquery_execute_effect('.divToAnimate', 'animate', array('options' => array('backgroundColor' => '#fff', 'color' => '#000', 'width' => 240), 'speed' => 1000)))))));
?>

<div class="divToAnimate" style="width:250px">
    <br>
    <p>Etiam libero neque, luctus a, eleifend nec, semper at, lorem. Sed pede. Nulla lorem metus, adipiscing ut, luctus sed, hendrerit vitae, mi.
    </p>
    <br>
</div>
  
<br>

<?php 
echo ui_button_pane_init($type = 'single', array('btnAnimate' => array('value' => 'Animate')));
echo ui_button_pane_end();
?>
Exemplo n.º 2
0
<div id="content">
		<p>
    <label>Test 1 (Local Data [Months]):</label>
    <input type="text" id="suggest1" />

    <?php 
echo jquery_autocomplete_support_to('#suggest1', array('data' => 'months'));
?>

    <?php 
jquery_ajax_event('#suggest15', 'success', like_function("alert('a')"));
?>

    <input type="button" value="Change data" id="btnSetOptions" />
    <?php 
echo jquery_execute(jquery_toggle_event('#btnSetOptions', array(like_function('changeToCities()'), like_function('changeToMonths()'))));
?>
    <br>
    <br>
    Test 2 (Local Data [Months] Multiple):
    <input type="text" id="suggest2" />

    <?php 
echo jquery_autocomplete_support_to('#suggest2', array('multiple' => true, 'highlight' => false, 'data' => 'months'));
?>
    <br>
    <br>
    Test 3 (Local Data [emails]):
    <input type="text" id="suggest3" />
    <?php 
echo jquery_autocomplete_support_to('#suggest3', array('data' => 'emails', 'formatItem' => like_function('return row.name.replace(new RegExp("(" + term + ")", "gi"), "<strong>$1</strong>") + "<br><span style=\'font-size: 80%;\'>Email: &lt;" + row.to + "&gt;</span>"', 'row, i, max, term'), 'formatResult' => like_function('return row.to', 'row')));
Exemplo n.º 3
0
<?php 
/* BEFORE the creation of jquery_execute function
  /*echo
      add_jquery_support(
      'document',
      'ready' ,
      like_function(
        jquery_toggle_event(
          'li',
          array(
            like_function('$(this).css({"list-style-type":"disc", "color":"blue"});'),
            like_function('$(this).css({"list-style-type":"disc", "color":"red"});'),
            like_function('$(this).css({"list-style-type":"", "color":"yellow"});'),
        )))); */
/* Now with jquery_execute*/
echo jquery_execute(jquery_toggle_event('li', array(like_function('$(this).css({"list-style-type":"disc", "color":"blue"});'), like_function('$(this).css({"list-style-type":"disc", "color":"red"});'), like_function('$(this).css({"list-style-type":"", "color":"yellow"});'))));
?>

<?php 
echo jquery_execute(jquery_hover_event('li', array(like_function('$(this).append($("<span> ******** </span>"));'), like_function('$(this).find("span:last").remove();'))));
?>

<br>

<hr>
<h3>Bind & Unbind - example</h3>

<input type="button" value="Bind" id="btnBind">
<input type="button" value="UnBind" id="btnUnBind">

<div id="bindExample">Click me</div>