WOOCS - WooCommerce-Währungsumschalter

Nennen Sie Ihren Preis – WooThemes

Plugin-Link: https://woocommerce.com/products/name-your-price/

  • im Ordner \wp-content\plugins\woocommerce-name-dein-preis\enthält\Klasse-WC-Name-Ihre-price-helpers.php Code hinzufügen:
    if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $price = $WOOCS->woocs_exchange_value(floatval($price)); } }

  • in der gleichen Datei Code hinzufügen:
    if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->current_currency != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $posted = $posted / $currencies[$WOOCS->current_currency]['rate']; } }

  • im gleichen Code Code hinzufügen:
    if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->is_multiple_allowed) { $price = $WOOCS->woocs_exchange_value(floatval($price)); } }

  • im gleichen Code Code hinzufügen:
    if (class_exists('WOOCS')) { global $WOOCS; $price = $WOOCS->woocs_exchange_value(floatval($price)); $minimum = $WOOCS->woocs_exchange_value(floatval($minimum)); }

  • Datei öffnen Plugins\woocommerce-name-Ihr-Preis\beinhaltet\Klasse-WC-name-your-price-cart.php und füge den nächsten Code hinzu:
    $price = (double) WC_Name_Your_Price_Helpers::standardize_number($_REQUEST[$posted_nyp_field]); if (class_exists('WOOCS')) { global $WOOCS; if ($WOOCS->current_currency != $WOOCS->default_currency) { $currencies = $WOOCS->get_currencies(); $price = $price / $currencies[$WOOCS->current_currency]['rate']; } } $cart_item_data['nyp'] = $preis;
    

    AND

    if (class_exists('WOOCS')) { global $WOOCS; $minimum = $WOOCS->woocs_exchange_value(floatval($minimum)); }