function eStore_save_trans_result_for_thank_you_page_display($payment_data, $constructed_download_link, $cart_items) { //$constructed_download_link - must have the values in HTML links $email_info = WP_ESTORE_YOU_WILL_SOON_RECEIVE_EMAIL . "(<strong>" . $payment_data['payer_email'] . "</strong>)<br />"; $offer_text = html_entity_decode(get_option('eStore_special_offer_text'), ENT_COMPAT, "UTF-8"); $additional_action_data = eStore_check_and_retrieve_action_data($payment_data, $cart_items); $_SESSION['eStore_tx_result'] = '<div class="eStore_thank_you_download_links">' . $constructed_download_link . '</div>'; if (!empty($additional_action_data)) { $_SESSION['eStore_tx_result'] .= '<div class="eStore_thank_you_additional_action_data">' . $additional_action_data . '</div>'; } $_SESSION['eStore_tx_result'] .= '<div class="eStore_thank_you_total_cost">' . WP_ESTORE_TOTAL_COST . ': ' . print_tax_inclusive_payment_currency_if_enabled($payment_data['mc_gross'], WP_ESTORE_CURRENCY_SYMBOL) . '</div>'; $_SESSION['eStore_tx_result'] .= '<div class="eStore_thank_you_txn_id">' . ESTORE_TRANSACTION_ID . ': ' . $payment_data['txn_id'] . '</div>'; $_SESSION['eStore_tx_result'] .= '<div class="eStore_thank_you_email">' . $email_info . '</div>'; if (!empty($offer_text)) { $_SESSION['eStore_tx_result'] .= '<div class="eStore_thank_you_offer">' . $offer_text . '</div>'; } $output = $_SESSION['eStore_tx_result']; $_SESSION['eStore_tx_result'] = apply_filters('eStore_tx_result_session_data', $output, $payment_data, $cart_items); //Gets fired before init action }
function show_product_fancy_style2($id, $button_type = 1, $show_price = 1, $restriction = '', $args = array()) { global $wpdb; $products_table_name = WP_ESTORE_PRODUCTS_TABLE_NAME; $ret_product = $wpdb->get_row("SELECT * FROM {$products_table_name} WHERE id = '{$id}'", OBJECT); $output = '<div class="eStore-product-fancy2">'; $output .= get_thumbnail_image_section_code($ret_product, "eStore-product-fancy2-thumb-image"); if (!empty($ret_product->product_url)) { $output .= '<div class="eStore-product-description"><div class="eStore-fancy2-product-name"><a href="' . $ret_product->product_url . '">' . $ret_product->name . '</a></div>'; } else { $output .= '<div class="eStore-product-description"><div class="eStore-fancy2-product-name">' . $ret_product->name . '</div>'; } //$output .= '<div class="eStore-product-description"><div class="eStore-product-name">'.$ret_product->name.'</div>'; $description = html_entity_decode($ret_product->description, ENT_COMPAT, "UTF-8"); $output .= do_shortcode($description); if (!empty($ret_product->available_copies)) { $output .= '<br /><strong>' . ESTORE_AVAILABLE_QTY . ': </strong>' . $ret_product->available_copies; } $output .= '</div></div>'; $output .= '<div class="eStore-product-fancy2-footer eStore-fancy-wrapper">'; $output .= '<div class="footer-left"><div class="footer-left-content">'; $output .= eStore_show_button_based_on_condition($id, $ret_product, $button_type, $restriction, '2', $args); $output .= '</div></div>'; if ($show_price == 1) { $conversion_rate = get_option('eStore_secondary_currency_conversion_rate'); if (!empty($conversion_rate)) { $secondary_curr_symbol = get_option('eStore_secondary_currency_symbol'); $secondary_curr_code = get_option('eStore_secondary_currency_code'); $secondary_curr_amt = number_format($ret_product->price * $conversion_rate, 2); $output .= '<div class="footer-right"><span class="eStore_fancy2_price">'; $output .= '<span class="eStore_price_label">' . ESTORE_PRICE . ': </span><span class="eStore_price_value">' . print_tax_inclusive_payment_currency_if_enabled($ret_product->price, WP_ESTORE_CURRENCY_SYMBOL, '', $ret_product) . '</span>'; $output .= ' (' . $secondary_curr_code . ' ' . print_tax_inclusive_payment_currency_if_enabled($secondary_curr_amt, $secondary_curr_symbol, '', $ret_product) . ')'; $output .= '</span>'; if (!empty($ret_product->old_price)) { $output .= '<span class="eStore_oldprice">' . ESTORE_OLD_PRICE . ': ' . print_tax_inclusive_payment_currency_if_enabled($ret_product->old_price, WP_ESTORE_CURRENCY_SYMBOL, '', $ret_product) . ' </span>'; } $output .= '</div>'; } else { $output .= '<div class="footer-right"><span class="eStore_fancy2_price"><span class="eStore_price_label">' . ESTORE_PRICE . ': </span><span class="eStore_price_value">' . print_tax_inclusive_payment_currency_if_enabled($ret_product->price, WP_ESTORE_CURRENCY_SYMBOL, '', $ret_product) . '</span></span>'; if (!empty($ret_product->old_price)) { $output .= '<span class="eStore_oldprice">' . ESTORE_OLD_PRICE . ': ' . print_tax_inclusive_payment_currency_if_enabled($ret_product->old_price, WP_ESTORE_CURRENCY_SYMBOL, '', $ret_product) . ' </span>'; } $output .= '</div>'; } } $output .= '</div>'; $output .= '<div class="eStore-clear-float"></div>'; return $output; }