This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function kursnbu( date ) { | |
if ( ! date ) { | |
return 0; | |
} | |
var apiUrl = 'https://bank.gov.ua/NBUStatService/v1/statdirectory/exchange?valcode=USD&date=', | |
dateApiFormat = Utilities.formatDate(date, "GMT+3", "yyyyMMdd"), | |
url = apiUrl + dateApiFormat + '&json', | |
response = UrlFetchApp.fetch( url ), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Responsible to modify the fonts list in the font control. | |
*/ | |
function modify_controls( $controls_registry ) { | |
// First we get the fonts setting of the font control | |
$fonts = $controls_registry->get_control( 'font' )->get_settings( 'fonts' ); | |
// Then we append the custom font family in the list of the fonts we retrieved in the previous step | |
$new_fonts = array_merge( [ 'Custom Font Family Name' => 'system' ], $fonts ); | |
// Then we set a new list of fonts as the fonts setting of the font control | |
$controls_registry->get_control( 'font' )->set_settings( 'fonts', $new_fonts ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'shortcode_atts_gallery', '__tm_modify_shortcode_atts_gallery', 10, 4 ); | |
function __tm_modify_shortcode_atts_gallery ( $out, $pairs, $atts, $shortcode ) { | |
$cherry_post_formats_api_args = __prifix_theme()->get_core()->modules['cherry-post-formats-api']->args; | |
if ( $cherry_post_formats_api_args['rewrite_default_gallery'] ) { | |
$out['link'] = $cherry_post_formats_api_args['gallery_args']['link']; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"Project-Id-Version: Jet Elements for Elementor\n" | |
"Report-Msgid-Bugs-To: \n" | |
"POT-Creation-Date: 2018-10-01 17:56+0300\n" | |
"PO-Revision-Date: 2018-08-29 14:14+0200\n" | |
"Last-Translator: \n" | |
"Language-Team: JetImpex\n" | |
"Language: en_US\n" | |
"MIME-Version: 1.0\n" | |
"Content-Type: text/plain; charset=UTF-8\n" | |
"Content-Transfer-Encoding: 8bit\n" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'jet-engine/listings/macros-list', '__your_prefix_add_jet_engine_new_marcos' ); | |
function __your_prefix_add_jet_engine_new_marcos( $list ) { | |
$list['current_year'] = '__your_prefix_jet_engine_current_year_cb'; | |
return $list; | |
} | |
function __your_prefix_jet_engine_current_year_cb() { | |
return mktime( 0, 0, 0, 1 , 1, date('Y') ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'jet-engine/listings/macros-list', '__your_prefix_add_jet_engine_new_marcos' ); | |
function __your_prefix_add_jet_engine_new_marcos( $list ) { | |
$list['current_day'] = '__your_prefix_jet_engine_current_day_cb'; | |
return $list; | |
} | |
function __your_prefix_jet_engine_current_day_cb() { | |
return mktime( 0, 0, 0, date( 'n' ), date( 'j' ), date( 'Y' ) ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'elementor/element/jet-listing-grid/section_general/before_section_end', '__your_prefix_update_posts_num_control', 10, 2 ); | |
function __your_prefix_update_posts_num_control( $widget = null, $args = array() ) { | |
$widget->update_control( | |
'posts_num', | |
array( | |
'max' => 1000, | |
) | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'jet-search/ajax-search/custom-post-data', '__your_prefix_add_custom_result_data', 10, 3 ); | |
function __your_prefix_add_custom_result_data( $post_data, $data, $post ) { | |
$custom_meta_value = get_post_meta( $post->ID, 'custom_post_meta', true ); | |
$post_data['custom'] = $custom_meta_value ? sprintf( '<div class="jet-ajax-search__custom-meta">%s</div>', $custom_meta_value ) : ''; | |
return $post_data; | |
} |
OlderNewer