이 사용자는 즐겨찾는 주제가 없습니다.
즐겨찾는 포럼 주제
생성한 포럼 주제
| 상태 |
주제
|
지원자 | 의견 | 게시물 | 최신 활동 |
|---|---|---|---|---|---|
|
Moneda dollar, pero con variación por países
시작: michelleG-8
카테고리: Soporte en español
Problema: /**
* Change a currency symbol for specific countries using WPML hooks
*/
add_filter('woocommerce_currency_symbol', 'change_existing_currency_symbol', 10, 2);
function change_existing_currency_symbol( $currency_symbol, $currency ) {
// Get the current country using WPML
$current_country = apply_filters('wpml_current_language', NULL);
if ($currency === 'USD') {
// Customize currency symbol based on country
if ($current_country === 'br') { // Brazil
$currency_symbol = 'USD R$';
} elseif ($current_country === 'co') { // Colombia
$currency_symbol = 'USD COL$';
} else {
$currency_symbol = 'USD'; // Default for other countries
}
}
return $currency_symbol;
}Además, se sugiere utilizar el complemento WooCommerce Product Price Based on Countries para gestionar precios diferenciados por país. |
|
0 | 7 | 1 년, 3 월 전에 | |
|
Uncaught Error: Class 'YITH_WAPO_WPML' not found
시작: michelleG-8 카테고리: Soporte en español |
|
2 | 2 | 4 년, 2 월 전에 |