Forum Replies Created
-
AuthorPosts
-
itzcoMember
Hi,
First of all, I agree the currency symbol is purely a cosmetic issue and you can simply use the buy now NOT fancy button. However, as I had to implement this minor change I’m sharing it in case someone needs it (Or you want to integrate in the plugin)
In the file: eStore_misc_functions.php
around line 806 :: Function show_product_fancy_style
Look for this line:
$output .= ‘<div class=”eStore_price”>‘.ESTORE_PRICE.’: ‘.print_tax_inclusive_payment_currency_if_enabled($ret_product->price,WP_ESTORE_CURRENCY_SYMBOL,”, $ret_product).'</div>’;
REPLACE this line with:
// Edit here for multi currency
$currency_symbols = array(‘AUD’=> ‘A$’, ‘CAD’ =>’C$’,’EUR’=>’€’, ‘GBP’=>’£’, ‘JPY’=>’¥’, ‘CHF’=>’CHF’,’HKD’=>’HKD $’,’SGD’=>’SGD $’,’BRL’=>’R$’,’MYR’=>’RM’,’THB’=>’฿’);
$price_csymbol = ‘$’;
if (array_key_exists( $ret_product->currency_code,$currency_symbols))
{
$price_csymbol = $currency_symbols[$ret_product->currency_code];
}
$output .= ‘<div class=”eStore_price”>‘.ESTORE_PRICE.’: ‘.print_tax_inclusive_payment_currency_if_enabled($ret_product->price,$price_csymbol,”, $ret_product).'</div>’;
//$output .= ‘<div class=”eStore_price”>‘.ESTORE_PRICE.’: ‘.print_tax_inclusive_payment_currency_if_enabled($ret_product->price,WP_ESTORE_CURRENCY_SYMBOL,”, $ret_product).'</div>’;
There you go, I didn’t add all the supported currencies but it would take no effort to add.
August 14, 2012 at 9:57 am in reply to: The plugin generated xxxx characters of unexpected output #22604itzcoMemberI was getting this error and went in to debug it, the plugin generates a number of notices here and there, mostly reading $_POST vars that are not set. Of course in most hostings it’s not a problem but on yours might be if you are here.
My specific fix:
My case (localhost, affiliate plugin) for a weird reason $wpdb was unset so lines 16-22 generated a lot of notices.
Fixed by adding this line before any use of var $wpdb (line 16)
if (!isset($wpdb)) $wpdb = $GLOBALS;
How to find what’s causing yours:
In the file: wp-admin/includes/plugin.php add to the file at the end (Change the path(wp-content/uploads/2012), this is just an example):
add_action(‘activated_plugin’,’save_error’);
function save_error(){
file_put_contents(ABSPATH. ‘wp-content/uploads/2012/error_activation.html’, ob_get_contents());
}
If you prefer to store the data in DB, check out this page and follow the complete instructions on debugging activation errors: http://hungrycoder.xenexbd.com/wordpress-2/how-i-have-solved-the-the-plugin-generated-xxxx-characters-of-unexpected-output-during-activation-problem.html
itzcoMemberHi,
Any news on this one? Would it be possible to autoupdate the exchange rate (As exchange rates are so crazy now)?
-
AuthorPosts