Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Support brianvu-tp

    (@briantp)

    Hi ihm365,

    Thank you for reaching out.

    Currently, LearnPress does not have a built-in feature to add a currency switcher below the course price.

    If you have any other questions or need further assistance, feel free to ask.

    Best regards,
    Brianvu-tp

    Thread Starter Imdad Hussain Mamud

    (@ihm365)

    Can you share other way how to implement it. It is very important for us otherwise we can not integrate Razorpay internationally.

    Plugin Support brianvu-tp

    (@briantp)

    Hi ihm365,

    Thank you for your follow-up.

    Could you please share if you have any specific suggestions or examples of how you would like the currency switcher to be implemented? This will help us check and provide you with a more accurate solution.

    We look forward to your response.

    Best regards,
    Brianvu-tp

    Thread Starter Imdad Hussain Mamud

    (@ihm365)

    See the Screenshot links on below. We want to add a currency switcher dropdown on the left side of the course price. e.g there is 2 currencies INR and USD. After select INR from dropdown, the the course price will converted to INR.

    Step 1: https://snipboard.io/F9o6ID.jpg

    Step 2: https://snipboard.io/hP3Une.jpg

    Step 3: https://snipboard.io/tMrfGv.jpg

    If there is any plugins, snippets also custom function, codes. Anything works for me. I will customize myself as per the requirements.

    Plugin Support brianvu-tp

    (@briantp)

    Hi ihm365,

    Thank you for providing the detailed screenshots and explanation.

    We now fully understand your requirements and have taken them into consideration. Currently, LearnPress doesn’t support a built-in currency switcher for courses, but based on your input, we will review this functionality as a potential add-on for future releases to ensure compatibility with LearnPress.

    If you have any other questions or suggestions, feel free to let us know.

    Best regards,
    Brianvu-tp

    Thread Starter Imdad Hussain Mamud

    (@ihm365)

    There are any custom code, function, snippet available to use here? Otherwise we have to use different plugin which takes lot of time and design the website from initial phase?

    Can you please help us?

    Plugin Support brianvu-tp

    (@briantp)

    Hi ihm365,

    Thank you for your patience.

    If you’d like to implement a custom currency switcher, you can modify the course price using LearnPress hooks. Here’s how you can do it:

    1. For the new model:
      You can use the following hook to modify the course price:
      apply_filters( 'learnPress/course/price', (float) $price, $this->get_id() ); 

      You can find this hook in the file:
      ‘wp-content/plugins/learnpress/inc/Models/CourseModel.php’

      2. For the old model:
      You can use the following hook:

      apply_filters( 'learn-press/course/price', $price, $this->get_id() );

      This hook is located in:
      ‘wp-content/plugins/learnpress/inc/course/abstract-course.php’

        By hooking into these filters, you can write custom code to adjust the course price based on the selected currency.

        This will give you the flexibility to implement a currency switcher as per your needs.

        Best regards,
        Brianvu-tp

      Viewing 7 replies - 1 through 7 (of 7 total)
      • You must be logged in to reply to this topic.