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
<?php | |
add_filter( 'redsys_modify_data_to_send', 'datos_modificados_pasarela_pago_en_redsys' ); // Filtro para «Redsys redirección (por Jose Conti)» | |
add_filter( 'bizum_modify_data_to_send', 'datos_modificados_pasarela_pago_en_redsys' ); // Filtro para «Bizum (por Jose Conti)» | |
function datos_modificados_pasarela_pago_en_redsys( $redsys_data_send ) { | |
$order_total_sign = $redsys_data_send['order_total_sign']; // Precio total | |
$terminal = $redsys_data_send['DSMerchantTerminal']; // Número de terminal | |
$currency = $redsys_data_send['currency']; // Moneda (código internacional numérico) | |
$transaction_id2 = $redsys_data_send['transaction_id2']; // Número de pedido |
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
<?php | |
// filtro para añadir las acciones al listado de entradas (post) | |
add_filter( 'bulk_actions-edit-post', 'prefijo_anadimos_acciones_bulk' ); | |
function prefijo_anadimos_acciones_bulk( $bulk_actions ) { | |
$bulk_actions['accion_primera_anadida'] = __( 'Esta es la acción primera', 'dominio_traduccion'); | |
$bulk_actions['accion_segunda_anadida'] = __( 'Esta es la acción segunda', 'dominio_traduccion'); | |
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
<?php | |
wp_embed_register_handler( 'gist', '/https?:\/\/gist\.github\.com\/([a-z0-9]+)\/([a-z0-9]+)?/i', 'joseconti_embed_gist' ); | |
function joseconti_embed_gist( $matches, $attr, $url, $rawattr ) { | |
$embed = sprintf( | |
'<script src="https://gist.github.com/%1$s/%2$s.js"></script>', | |
esc_attr( $matches[1] ), | |
esc_attr( $matches[2] ) | |
); |
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
# QTRANSLATE CLEANUP QUERIES | |
# create temp column to separate post content on <!--more--> tag to simplify queries | |
ALTER TABLE `wp_posts` ADD `tmp_excerpt` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL; | |
ALTER TABLE `wp_4_posts` ADD `tmp_excerpt` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL; | |
ALTER TABLE `wp_3_posts` ADD `tmp_excerpt` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL; | |
# split content |
NewerOlder