Support » Plugin: Payment Gateway Based Fees and Discounts for WooCommerce » Getting lowest price anywhere

  • I’m showing the lowest price all over the store, but there is no easy way to get this information, only this shortcode [alg_show_checkout_fees_lowest_price_info] that renders as HTML. But for feeds, I need the price in raw data, not HTML and I didn’t find any function to get this.

    I’m suggesting to add arguments to this shortcode, so I could change the template and product ID to return.

    [alg_show_checkout_fees_lowest_price_info product="123" template="%product_gateway_price%"]

    And for raw data, only float price value with no tags, you could add another tag.

    %product_gateway_price_raw%

    Or maybe, in this case, instead of use a shortcode, you could provide functions.

    alg_get_lowest_price_html($product_id, $template) // with HTML tags
    alg_get_lowest_price($product_id) // raw price value 123.00

    Another thing, please, reduce the tab name from “Payment Gateway Based Fees and Discounts” to something like “Fees and Discounts”.

    • This topic was modified 1 year, 10 months ago by Edir Pedro.
    • This topic was modified 1 year, 10 months ago by Jan Dembowski.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Another idea could be a function to return just the array of values, including raw price values.

    $lowest_price_array[] = array(
    	'gateway_title'
    	'gateway_description'
    	'gateway_icon'
    	'product_gateway_price'
    	'product_gateway_price_raw', // Including float value 1234.00
    	'product_original_price'
    	'product_original_price_raw', // Including float value 1234.00
    	'product_price_diff'
    	'product_price_diff_percent'
    	'product_title'
    	'product_variation_atts'
    );

    alg_get_lowest_price($product_id)

    Hi Edir,

    Thank you for providing us with the shortcodes which you are using on your site and for the suggestions.

    In order to show the lowest price info on the single product page then there is a setting named as ‘Lowest price info on single product page’ which when enabled allows achieving this.

    Attaching a screenshot for your reference: https://prnt.sc/limp7a , product page: https://prnt.sc/limpj1

    Please let me know if I misunderstood your requirement which you want to achieve with necessary screenshots. This would help me in understanding immensely and then assist you in a better way.

    Regards,
    Komal Maru

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Getting lowest price anywhere’ is closed to new replies.