本文整理汇总了PHP中Essential_Grid_Base::jsonEncodeForClientSide方法的典型用法代码示例。如果您正苦于以下问题:PHP Essential_Grid_Base::jsonEncodeForClientSide方法的具体用法?PHP Essential_Grid_Base::jsonEncodeForClientSide怎么用?PHP Essential_Grid_Base::jsonEncodeForClientSide使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Essential_Grid_Base
的用法示例。
在下文中一共展示了Essential_Grid_Base::jsonEncodeForClientSide方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
echo $save;
?>
</a></div>
<?php
Essential_Grid_Dialogs::fontello_icons_dialog();
Essential_Grid_Dialogs::global_css_edit_dialog();
Essential_Grid_Dialogs::meta_dialog();
Essential_Grid_Dialogs::edit_advanced_rules_dialog();
?>
</div>
<script type="text/javascript">
jQuery(function(){
GridEditorEssentials.setInitElementsJson(<?php
echo $base->jsonEncodeForClientSide($elements);
?>
);
GridEditorEssentials.setInitFontsJson(<?php
echo $base->jsonEncodeForClientSide($fonts_full);
?>
);
GridEditorEssentials.setInitAllAttributesJson(<?php
echo $base->jsonEncodeForClientSide($all_attributes);
?>
);
GridEditorEssentials.setInitMetaKeysJson(<?php
echo $base->jsonEncodeForClientSide($meta_keys);
示例2: jQuery
e.preventDefault();
var setto = jQuery(this).data('setto');
jQuery('#'+setto).val('');
jQuery('#'+setto+'-img').attr("src","");
jQuery('#'+setto+'-img').hide();
return false;
});
<?php
if (!isset($disable_advanced) || $disable_advanced == false) {
?>
AdminEssentials.setInitSkinsJson(<?php
echo $base->jsonEncodeForClientSide($advanced);
?>
);
AdminEssentials.setInitElementsJson(<?php
echo $base->jsonEncodeForClientSide($eg_meta);
?>
);
AdminEssentials.setInitStylingJson(<?php
echo $base->jsonEncodeForClientSide($eg_elements);
?>
);
AdminEssentials.initMetaBox();
<?php
}
示例3: add_tiny_mce_shortcode_dialog
//.........这里部分代码省略.........
echo '<div class="ess-grid-tiny-' . $handle . '-wrap ess-grid-tiny-elset-row" style="display: none;"><div class="ess-grid-tiny-elset-label" for="' . $handle . '">' . $name['name'] . ':</div><input name="ess-grid-tiny-' . $handle . '[]" value="" /></div>';
}
}
?>
</div>
<div style="clear:both"></div>
<div style="width:100%;height:30px;"></div>
</div>
<div class="ess-grid-tiny-custom-pictogram"><div class="dashicons dashicons-format-image"></div></div>
<div class="esg-toolbutton esg-delete-item">
<a href="javascript:void(0);" class="esg-tiny-delete-entry"><div class="dashicons dashicons-trash"></div></a>
</div>
<div class="esg-toolbutton esg-collapsme-item">
<a href="javascript:void(0);" class="esg-tiny-collapsme-entry"><div class="dashicons dashicons-sort"></div></a>
</div>
<img class="esg-toolbarimg" src="">
</div>
<script type="text/javascript">
<?php
$skin_layers = array();
$all_skins = $skins_c->get_essential_item_skins();
if (!empty($all_skins)) {
foreach ($all_skins as $cskin) {
$custom_layer_elements = array();
if (isset($cskin['layers'])) {
foreach ($cskin['layers'] as $layer) {
if (@isset($layer['settings']['source'])) {
switch ($layer['settings']['source']) {
case 'post':
$custom_layer_elements[@$layer['settings']['source-post']] = '';
break;
case 'woocommerce':
$custom_layer_elements[@$layer['settings']['source-woocommerce']] = '';
break;
}
}
}
}
$skin_layers[$cskin['id']] = $custom_layer_elements;
}
}
?>
var esg_tiny_skin_layers = jQuery.parseJSON(<?php
echo $base->jsonEncodeForClientSide($skin_layers);
?>
);
// KRIKI SCRIPT
var esgCustomCollapser = function(bt,direction) {
var cp = bt.closest('.esg-tiny-element'),
cpitem = cp.find('.ess-grid-tiny-collapse-wrapper'),
timg = cp.find('.esg-toolbarimg'),
pimg = cp.find('.esg-tiny-preshow-img');
if ((direction=="auto" && cpitem.hasClass("collapsed")) || direction=="open") {
cpitem.slideDown(200);
cpitem.removeClass("collapsed");
bt.removeClass("collapsed");
timg.removeClass("collapsed");
} else {
cpitem.slideUp(200);
cpitem.addClass("collapsed");
bt.addClass("collapsed");
timg.addClass("collapsed");
jQuery.each(pimg,function(index,pimge) {
if (jQuery(pimge).attr('src') !=undefined && jQuery(pimge).attr('src').length>0)
timg.attr('src',jQuery(pimge).attr('src'));
})
}
}
jQuery('body').on('click','.esg-toolbutton.esg-collapsme-item',function() {
esgCustomCollapser(jQuery(this),"auto");
});
jQuery('.ess-mediaselector.collapseall').click(function() {
var ca = jQuery(this);
if (ca.hasClass("collapsed")) {
jQuery('.esg-toolbutton.esg-collapsme-item').each(function() {
esgCustomCollapser(jQuery(this),"open");
})
ca.removeClass("collapsed");
} else {
jQuery('.esg-toolbutton.esg-collapsme-item').each(function() {
esgCustomCollapser(jQuery(this),"close");
})
ca.addClass("collapsed");
}
})
</script>
</div>
<?php
}
示例4: array
$columns_width = $base->set_basic_colums_width($columns_width);
$columns_height = $base->getVar($grid['params'], 'columns-height', '');
$columns_height = $base->set_basic_colums_height($columns_height);
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-0', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-1', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-2', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-3', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-4', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-5', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-6', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-7', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-8', '');
$columns_advanced[] = $base->getVar($grid['params'], 'columns-advanced-rows-9', '');
$nav_skin_choosen = $base->getVar($grid['params'], 'navigation-skin', 'minimal-light');
$navigation_skins = $nav_skin->get_essential_navigation_skins();
$navigation_skin_css = $base->jsonEncodeForClientSide($navigation_skins);
$entry_skins = Essential_Grid_Item_Skin::get_essential_item_skins();
$entry_skin_choosen = $base->getVar($grid['params'], 'entry-skin', '0');
$grid_animations = $base->get_grid_animations();
$hover_animations = $base->get_hover_animations();
$grid_animation_choosen = $base->getVar($grid['params'], 'grid-animation', 'fade');
$hover_animation_choosen = $base->getVar($grid['params'], 'hover-animation', 'fade');
if (intval($isCreate) > 0) {
//currently editing, so default can be empty
$media_source_order = $base->getVar($grid['postparams'], 'media-source-order', '');
} else {
$media_source_order = $base->getVar($grid['postparams'], 'media-source-order', array('featured-image'));
}
$media_source_list = $base->get_media_source_order();
$custom_elements = $base->get_custom_elements_for_javascript();
$all_image_sizes = $base->get_all_image_sizes();