Post Pay Counter

The best way to pay authors on WordPress

  • Features
    • PRO version
  • Cart
    • Addons
  • Documentation
  • Support

Error with payment request button

by

› Forums › Request Payment › Error with payment request button

We are based in Europe with a GMT+1/GMT+2 time zone - support replies may be delayed due to time zone differences with your country.

  • This topic has 3 replies, 2 voices, and was last updated 6 years ago by Stefano.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • May 1, 2019 at 7:04 pm #64847
    UD
    Guest

    Hello,

    When clicking the request button on the frontend, I get this error “Uncaught ReferenceError: ajaxurl is not defined”.

    The button works fine on the admin area. Any insight to help me solve it would be much appreciated!

    May 1, 2019 at 8:54 pm #64850
    Stefano
    Keymaster

    Uhm, could you please try to deactivate all other plugins that have a front-end impact and try again? Just for a second to see if it’s a conflict with something else 🙂 let me know!

    Have a nice day,
    Stefano

    May 2, 2019 at 8:39 pm #64875
    UD
    Guest

    Thank you for reply!
    I disabled plugins and tried the shortcode in a static page, but still got the same error until I added this code to functions.php

    add_action('wp_head', 'myplugin_ajaxurl');
    
    function myplugin_ajaxurl() {
        echo '<script type="text/javascript">
               var ajaxurl = "' . admin_url('admin-ajax.php') . '";
             </script>';
    }

    Just in case someone else is having the same issues.

    I have another question if you don’t mind, is there a way to disable the request button if the author didn’t have a PayPal email address saved to their profile?

    Thank you for the great work you’ve done with the plugin!

    May 2, 2019 at 10:18 pm #64886
    Stefano
    Keymaster

    Thanks for sharing! 🙂

    I have another question if you don’t mind, is there a way to disable the request button if the author didn’t have a PayPal email address saved to their profile?

    Not currently, I am afraid :\

    • This reply was modified 6 years ago by Stefano.
  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Error with payment request button’ is closed to new replies.

Your cart

Number of items in cart: 0

  • Your cart is empty.
  • Total: €0.00
  • Checkout

What are you looking for?

BEFORE POSTING

Before posting, please please please do have a look at our Documentation section. Your problem may be addressed there, allowing you to solve it without help from us :)

Copyright © 2025 · Centric Theme on Genesis Framework · WordPress · Log in