本文整理汇总了PHP中like_function函数的典型用法代码示例。如果您正苦于以下问题:PHP like_function函数的具体用法?PHP like_function怎么用?PHP like_function使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了like_function函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: ui_layout_configure_to
/**
* UI.Layout creates a 'page-layout' that has auto-sizing 'center pane'
* surrounded by up to four collapsible and resizable 'border panes'
* (north, south, east & west). It can also create multiple headers &
* footers inside each pane.
* @param string $layoutName The layout name
* @param string $selector jQuery Selector
* @param array() $configurations Array. See the options and events in
* http://layout.jquery-dev.net/documentation.html#Options
*/
function ui_layout_configure_to($layoutName, $selector, $configurations = array())
{
$configurations = get_default_widget_configuration('app_ys_jquery_ui_layout_defaults', $configurations);
if (isset($configurations['yml'])) {
$ymlItems = sfYaml::load($configurations['yml']);
$ymlIndex = isset($configurations['ymlKey']) ? $configurations['ymlKey'] : 'layout';
$ymlConfigurations = isset($ymlItems[$ymlIndex]) ? $ymlItems[$ymlIndex] : array();
$configurations = array_merge($ymlConfigurations, $configurations);
unset($configurations['yml'], $configurations['ymlKey']);
}
$support = core_init_javasacript_tag();
$support .= 'var ' . $layoutName . ';';
$pattern = ui_layout_pattern($configurations);
$utilityMethods = '';
if (!is_array($configurations) || !sizeof($configurations) > 0) {
$configurations = array('applyDefaultStyles' => true);
} else {
if (!isset($configurations['name'])) {
$configurations['name'] = $layoutName;
}
$utilityMethods = ui_layout_utility_methods_pattern($layoutName, $configurations);
}
if (isset($configurations['cache']) && $configurations['cache'] === true) {
echo add_jquery_support('window', 'unload', like_function("layoutState.save('{$layoutName}')"));
$pattern = "\$.extend( {$pattern} , layoutState.load('{$layoutName}'))";
}
$jsVar = like_function($layoutName . ' = ' . jquery_support($selector, 'layout', $pattern, true, $utilityMethods));
$support .= jquery_support($selector, 'ready', $jsVar);
echo $support .= core_end_javasacript_tag();
}
示例2: ui_datepicker_set_defaults
/**
* Set settings for all datepicker instances
* @param array() $defaults The default values. see app.yml
* ys_jquery_ui_datepicker_defaults index
* @param boolean $isInternal if the helper is executed within a javascript function
*/
function ui_datepicker_set_defaults($defaults = array(), $isInternal = false)
{
$pattern = '';
$addDefaults = false;
if (is_array($defaults) && sizeof($defaults) > 0) {
$pattern = _ui_datepicker_pattern($defaults);
$addDefaults = true;
}
$appDefaults = sfConfig::get('app_ys_jquery_ui_datepicker_defaults', array());
if (is_array($appDefaults) && sizeof($appDefaults) > 0) {
$appDefaults = array_merge($defaults, $appDefaults);
$pattern = _ui_datepicker_pattern($appDefaults);
$addDefaults = true;
}
if ($addDefaults) {
if ($isInternal) {
return jquery_support(null, 'datepicker.setDefaults', $pattern);
} else {
return add_jquery_support('document', 'ready', like_function(jquery_support(null, 'datepicker.setDefaults', $pattern)));
}
}
}
示例3: ui_button_pane_end
echo ui_button_pane_end();
?>
</fieldset>
<?php
/*
* Add jQuery support to the buttons above
* **click event**
*/
echo add_jquery_support("#btnDestroyAccordion", 'click', like_function(ui_accordion_destroy('#accordionId')));
echo add_jquery_support("#btnBuildAccordion", 'click', like_function(ui_accordion_build('#accordionId', array('event' => 'mouseover'))));
echo add_jquery_support("#btnDisableAccordion", 'click', like_function(ui_accordion_disable('#accordionId')));
echo add_jquery_support("#btnEnableAccordion", 'click', like_function(ui_accordion_enable('#accordionId')));
echo add_jquery_support("#btnActivateAccordion", 'click', like_function(ui_accordion_activate('#accordionId', 0)));
echo add_jquery_support("#btnGetAccordionOption", 'click', like_function("getAccordionOption()"));
echo add_jquery_support("#btnSetAccordionOption", 'click', like_function("setAccordionOption()"));
?>
<script type="text/javascript" language="javascript">
function getAccordionOption(){
option = <?php
echo ui_accordion_get_option('#accordionId', 'event');
?>
alert('The accordion event is ' + option);
}
function setAccordionOption(){
<?php
echo ui_accordion_set_options('#accordionId', array('collapsible' => true));
?>
alert('Now sections can be closed');
}
</script>
示例4: jquery_autocomplete_support_to
?>
</td>
<td>
OPERATIVO:
</td>
<td>
<?php
echo $operativo['operativo_id']->render();
?>
</td>
<td>
<input type="submit" value="Buscar" id ="btnBuscar" />
</td>
</tr>
</table>
<?php
echo jquery_autocomplete_support_to('#dat_sie_operativos_ue', array('url' => url_for('adultoshumanisticainformacion/autocompleteData'), 'max' => 20, 'width' => 300, 'highlight' => false, 'formatItem' => like_function('return row[0] + " - <strong> " + row[1] + "</strong>"', 'row'), 'formatResult' => like_function('return row[0].replace(/(<.+?>)/gi, "")', 'row')));
?>
</form>
<?php
echo ui_end_content();
echo ui_end_content_panel();
?>
</div>
<?php
echo jquery_ajax_form('#myForm', array('url' => url_for($ue), 'success' => like_function("\$('#divResults').html(data)", 'data'), 'condition' => '$("#dat_sie_operativos_ue").attr("value") != ""', 'onFailureCondition' => 'alert("Debe registrar el SIE de la unidad educativa")', 'type' => 'POST'));
echo jquery_ajax_event('#dat_sie_operativos_ue', 'ajaxSuccess', like_function('$("#imagen").css("display","none")', 'event,request,settings'));
echo jquery_ajax_event('#dat_sie_operativos_ue', 'ajaxStart', like_function('$("#imagen").css("display","block")', 'event,request,settings'));
?>
示例5: ui_button_pane_end
<?php
echo ui_button_pane_end();
?>
</fieldset>
<?php
/*
* Add jQuery support to the buttons above
* **click event**
*/
echo add_jquery_support("#btnDestroyProgressbar", 'click', like_function(ui_progressbar_destroy('#progressbar')));
echo add_jquery_support("#btnDisableProgressbar", 'click', like_function(ui_progressbar_disable('#progressbar')));
echo add_jquery_support("#btnEnableProgressbar", 'click', like_function(ui_progressbar_enable('#progressbar')));
echo add_jquery_support("#btnSetValueProgressbar", 'click', like_function('changeValue()'));
echo add_jquery_support("#btnGetValueProgressbar", 'click', like_function('getValue()'));
echo add_jquery_support("#btnAnimateProgressbar", 'click', like_function(ui_progressbar_animate('#progressbar2', 5)));
?>
<script type="text/javascript" language="javascript">
function changeValue(){
value = Math.ceil(Math.random() * 99);
<?php
echo ui_progressbar_set_value('#progressbar', 'value');
?>
<?php
echo jquery_support('#lblValue', 'html', "value + '%'");
?>
}
function getValue(){
value = <?php
示例6: foreach
<select style="font-family: Arial;font-size: 12px;" id="unidad_educativa">
<option value="-999">[Seleccionar]</option>
<?php
foreach ($unidades as $unidad) {
?>
<option value="<?php
echo $unidad->getCodUe();
?>
"><?php
echo $unidad->getCodUe() . ' - ' . $unidad->getDescUe();
?>
</option>
<?php
}
?>
</select>
<?php
echo jquery_ajax(array('listener' => array('selector' => '#unidad_educativa', 'event' => 'change'), 'url' => url_for('adultoshumanisticacrear/subcentro'), 'success' => like_function("\$('#subcentro').html(data)", 'data'), 'data' => "'ue_id=' + " . jquery_get('this', 'val') . "+'&periodo_id='+document.getElementById('periodo_id').value", 'type' => 'POST'));
?>
<?php
echo jquery_ajax_event('#unidad_educativa', 'ajaxSuccess', like_function('$("#imagen").css("display","none")', 'event,request,settings'));
echo jquery_ajax_event('#unidad_educativa', 'ajaxStart', like_function('$("#imagen").css("display","block")', 'event,request,settings'));
示例7: use_helper
<?php
use_helper('JavascriptBase');
use_helper('ysJQueryRevolutions');
use_helper('ysJQueryUIDialog');
?>
<?php
ui_dialog_init('dialogId', array('title' => 'Bienvenidos a Sifact', 'modal' => true, 'buttons' => array('Cerrar' => like_function(ui_dialog_close('this')))), 'class="myCustomClass" style=".myCustomStyle"');
?>
<p align="justify">
Sifact es el sistema de facturación electróica confiable, seguro y de
alta disponibilidad el cual le ayudará de una manera sencilla e intuitiva
a realizar todos sus movimientos de facturación de sus clientes.
</p>
<?php
ui_dialog_end();
?>
<h1>Sistema de facturación electróica</h1>
Para facturar, es necesario que siga los siguientes pasos:
<ul>
<li>Actualice sus datos en <a href="<?php
echo url_for('@profile');
?>
">Mi Perfil</a></li>
<li>Registre la Información de sus <a href="<?php
echo url_for('@client');
示例8: jquery_load
echo $page;
?>
</a>
<?php
echo jquery_load('#result', array('listener' => array('selector' => '#page' . $page, 'event' => 'click'), 'url' => url_for($url), 'data' => array('page' => $page, 'ue_id' => $ue_id, 'subcea_id' => $subcea_id, 'modalidad_id' => $modalidad_id, 'nivel_id' => $nivel_id, 'ciclo_id' => $ciclo_id, 'paralelo_id' => $paralelo_id, 'turno_id' => $turno_id)));
?>
<?php
}
?>
<?php
}
?>
<a href="#" id="next">
<img src="/images/next.png" alt="Siguiente Página" title="Siguiente Página" border="0" />
</a>
<a href="#" id="last">
<img src="/images/last.png" alt="Ultima página" title="Ultima Página" border="0"/>
</a>
</div>
<?php
echo jquery_load('#result', array('listener' => array('selector' => '#first', 'event' => 'click'), 'url' => url_for($url), 'data' => array('page' => '1', 'ue_id' => $ue_id, 'subcea_id' => $subcea_id, 'modalidad_id' => $modalidad_id, 'nivel_id' => $nivel_id, 'ciclo_id' => $ciclo_id, 'paralelo_id' => $paralelo_id, 'turno_id' => $turno_id)));
echo jquery_load('#result', array('listener' => array('selector' => '#previous', 'event' => 'click'), 'url' => url_for($url), 'data' => array('page' => $pager->getPreviousPage(), 'ue_id' => $ue_id, 'subcea_id' => $subcea_id, 'modalidad_id' => $modalidad_id, 'nivel_id' => $nivel_id, 'ciclo_id' => $ciclo_id, 'paralelo_id' => $paralelo_id, 'turno_id' => $turno_id)));
echo jquery_load('#result', array('listener' => array('selector' => '#next', 'event' => 'click'), 'url' => url_for($url), 'data' => array('page' => $pager->getNextPage(), 'ue_id' => $ue_id, 'subcea_id' => $subcea_id, 'modalidad_id' => $modalidad_id, 'nivel_id' => $nivel_id, 'ciclo_id' => $ciclo_id, 'paralelo_id' => $paralelo_id, 'turno_id' => $turno_id)));
echo jquery_load('#result', array('listener' => array('selector' => '#last', 'event' => 'click'), 'url' => url_for($url), 'data' => array('page' => $pager->getLastPage(), 'ue_id' => $ue_id, 'subcea_id' => $subcea_id, 'modalidad_id' => $modalidad_id, 'nivel_id' => $nivel_id, 'ciclo_id' => $ciclo_id, 'paralelo_id' => $paralelo_id, 'turno_id' => $turno_id)));
?>
<?php
echo jquery_ajax_event('#result', 'ajaxSuccess', like_function('$("#imagen").css("display","none")', 'event,request,settings'));
echo jquery_ajax_event('#result', 'ajaxStart', like_function('$("#imagen").css("display","block")', 'event,request,settings'));
echo jquery_ajax_event('#result', 'ajaxError', like_function('$("#imagen").css("display","block")', 'event,request,settings'));
示例9: ui_progressbar_init_animation
/**
* Shows the progress in the progressbar. For use in an event.
* @param string $selector jQuery Selector
* @param integer $delay Delay in seconds. Default 5 sec.
*/
function ui_progressbar_init_animation($selector, $delay = 5)
{
$percentageChar = '%';
$pattern = _ui_progressbar_animation_pattern();
return jquery_support($selector, 'ready', like_function(sprintf($pattern, $selector, $percentageChar, $delay)));
}
示例10: ui_grid_td_init
?>
<?php
ui_grid_td_init('style="text-align:left;width:32px;"');
?>
<?php
//echo $estudiante['codigo_rude'];
?>
<a href="#" id = <?php
echo 'modal' . $i;
?>
><strong><?php
echo $estudiante['codigo_rude'];
?>
</strong></a>
<?php
echo jquery_ajax(array('listener' => array('selector' => '#modal' . $i, 'event' => 'click'), 'url' => url_for('estudiantealtbusqueda/listainscripciones'), 'success' => like_function("\$('#divUes').html(data)", 'data'), 'data' => "'codigo_rude='+'" . $estudiante['codigo_rude'] . "'", 'type' => 'GET'));
?>
<?php
ui_grid_td_end();
?>
<?php
ui_grid_td_init('style="text-align:left;width:66px;"');
?>
<?php
echo $estudiante['paterno'];
?>
<?php
ui_grid_td_end();
?>
<?php
示例11: ui_button_pane_init
</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();
?>
示例12: use_helper
<?php
use_helper('ysJQueryRevolutions');
?>
Frameworks: <strong><span id="divResults"></span></strong>
<hr>
<h3>Ajax events - example</h3>
<br>
<input type="button" id="btnReloadAjax" value="Click here"/>
<?php
echo jquery_ajax(array('listener' => array('selector' => '#btnReloadAjax', 'event' => 'click'), 'url' => url_for('jquery_demo/getjson'), 'dataType' => 'json', 'confirmation' => 'Do you want ajax submit', 'onNoConfirmation' => 'alert("Not submitted")', 'success' => like_function("\$('#divResults').html(data.frameworks.toString())", 'data'), 'data' => "'cboIdLenguage=' + Math.ceil(Math.random() * 3)", 'type' => 'GET'));
?>
<?php
echo jquery_ajax_event('#btnReloadAjax', 'ajaxComplete', like_function("alert('Complete')"));
echo jquery_ajax_event('#btnReloadAjax', 'ajaxSend', like_function("alert('Send')", 'event,request,settings'));
echo jquery_ajax_event('#btnReloadAjax', 'ajaxStop', like_function("alert('Stop')", 'event,request,settings'));
echo jquery_ajax_event('#btnReloadAjax', 'ajaxSuccess', like_function("alert('Success')", 'event,request,settings'));
echo jquery_ajax_event('#btnReloadAjax', 'ajaxStart', like_function("alert('Start')", 'event,request,settings'));
echo jquery_ajax_event('#btnReloadAjax', 'ajaxError', like_function("alert('Error')", 'event,request,settings'));
?>
示例13: ui_end_content_panel
echo ui_end_content_panel();
?>
</div><!-- End demo -->
<div class="demo-description">
<p>Combine horizontal and vertical sliders, each with their own options, to create the UI for a music player.</p>
</div><!-- End demo-description -->
<fieldset><legend>Example - Actions buttons for ui.slider</legend>
<?php
echo ui_button_pane_init($type = 'single', array('btnDestroySlider' => array('value' => 'Destroy Slider'), 'btnDisableSlider' => array('value' => 'Disable Slider'), 'btnEnableSlider' => array('value' => 'Enable Slider'), 'btnSetValueSlider' => array('value' => 'Set Slider1 value = 50'), 'btnSetValuesSlider' => array('value' => 'set Slider2[0] value = 15')));
?>
<?php
echo ui_button_pane_end();
?>
</fieldset>
<?php
/*
* Add jQuery support to the buttons above
* **click event**
*/
echo add_jquery_support("#btnDestroySlider", 'click', like_function(ui_slider_destroy('#slider1')));
echo add_jquery_support("#btnDisableSlider", 'click', like_function(ui_slider_disable('#slider1')));
echo add_jquery_support("#btnEnableSlider", 'click', like_function(ui_slider_enable('#slider1')));
echo add_jquery_support("#btnSetValueSlider", 'click', like_function(ui_slider_value('#slider1', 50)));
echo add_jquery_support("#btnSetValuesSlider", 'click', like_function(ui_slider_values('#slider2', 0, 15)));
?>
<br>
<?php
echo link_to('jquery UI (slider) documentation', 'http://jqueryui.com/demos/slider');
示例14: jquery_ajax_get_request
<hr>
<br>
<h3>jquery.get request- example</h3>
<input type="button" value="Request [GET]" id="btnGet" />
<?php
echo jquery_ajax_get_request(array('listener' => array('selector' => '#btnGet', 'event' => 'click'), 'url' => url_for('jquery_demo/getjson'), 'callback' => like_function('alert("GET: Data SUCCESS: " + data);', 'data'), 'data' => array('cboIdLenguage' => '1')));
?>
<hr>
<br>
<h3>jquery.post request - example</h3>
<input type="button" value="Request [POST]" id="btnPost" />
<?php
echo jquery_ajax_post_request(array('listener' => array('selector' => '#btnPost', 'event' => 'click'), 'url' => url_for('jquery_demo/getjson'), 'callback' => like_function('alert("POST: Data SUCCESS: " + data);', 'data'), 'data' => array('cboIdLenguage' => '2')));
?>
<hr>
<br>
<h3>Get json - example</h3>
<input type="button" value="Get JSON" id="btnGetJson" />
<?php
echo jquery_get_json(array('listener' => array('selector' => '#btnGetJson', 'event' => 'click'), 'url' => url_for('jquery_demo/getjson'), 'callback' => like_function('alert(data.frameworks)', 'data'), 'data' => array('cboIdLenguage' => '2')));
?>
<hr>
示例15: ui_button_pane_end
<?php
echo ui_button_pane_end();
?>
</fieldset>
<?php
/*
* Add jQuery support to the buttons above
* **click event**
*/
echo add_jquery_support("#btnDestroyDrag", 'click', like_function(ui_draggable_destroy('#draggable')));
echo add_jquery_support("#btnBuildDrag", 'click', like_function(ui_draggable_build('#draggable')));
echo add_jquery_support("#btnDisableDrag", 'click', like_function(ui_draggable_disable('#draggable')));
echo add_jquery_support("#btnEnableDrag", 'click', like_function(ui_draggable_enable('#draggable')));
echo add_jquery_support("#btnSetDragOption", 'click', like_function("setOption()"));
echo add_jquery_support("#btnGetDragOption", 'click', like_function("getOption()"));
?>
<script type="text/javascript" language="javascript">
function getOption(){
option = <?php
echo ui_draggable_get_option('#draggable', 'axis');
?>
alert('The draggable axis value is: ' + option);
}
function setOption(){
option = <?php
echo ui_draggable_set_options('#draggable', array('axis' => 'x'));
?>
alert('Now the axis is only horizontal');
}