Plugin not passing information to PayPal

I've set up this plugin to handle appointments for a client here: http://www.breckweddings.com/planning/make-an-appointment/

Can you take a look at that page real quick? Choose an appointment and then look at the button at the bottom of the page - it doesn't refresh with the correct price or service name. Also, if clicked, that button leads to a PayPal payment page with a product just called SERVICE and a price of $0.00. Can you help me figure out why it's not working?

  • Hakan
    • The Incredible Smush

    Hi,

    You have a javascript error on the page. Please check it by opening the page with Google Chrome or Firefox and pressing Ctrl+Shift+j.

    The most likely reason is you are calling jQuery twice. Remove this line from your theme:

    <script src="http://www.breckweddings.com/cms/wp-content/themes/breckweddings/scripts/jquery-1.7.1.min.js" type="text/javascript"></script>

    Also I see that javascript codes on the footer are loaded twice. Switch to the default theme first to confirm that this is theme issue. Your theme may be calling wp_footer twice.

    Is this a custom theme?

    Cheers,
    Hakan

  • eastonellsworth
    • New Recruit

    Thanks Hakan! Yes, it is a custom theme which I inherited from another developer a few moons ago.

    So far I've removed that pesky duplicate call to jQuery and made sure wp_footer is only getting called once - at least it only appears once in the footer.php template. The issue persisted so I went ahead and switched to the default theme as per your suggestion. Unfortunately, the problem still exists.

    Not sure if this helps anyone who may have the solution, but my first visual cue that something isn't right is when that Make an Appointment page first loads and I click on an appointment date and then time - upon clicking on the time, two spinning circle indicators appear by the mouse pointer instead of one.

    I'm running WP 3.4.2 and v1.0.9 of Appointments+.

  • Hakan
    • The Incredible Smush

    Hi,

    I still see an issue:

    Uncaught ReferenceError: $ is not defined

    Please fix every javascript problem first.

    Open the page with Google Chrome or Firefox and press ctrl+shift+j. You can simply see from there that gloabl-init.js is not suitable for a WordPress website.

    Please check every time that you don't have any more javascript errors on the page.

    This is wrong for WordPress (Not specific to this plugin):

    $(document).ready(function(){

    This is correct:

    jQuery(document).ready(function($){

    Please see this:
    http://codex.wordpress.org/Function_Reference/wp_enqueue_script#jQuery_noConflict_wrappers

    Cheers,
    Hakan

  • eastonellsworth
    • New Recruit

    Thanks Hakan. Sadly, I think this particular site has some severe issues that go beyond what your tips are able to solve - despite my doing exactly what you said, the issue has persisted.

    I've even tried the usual standbys of deactivating and reactivating plugins, switching themes, etc. Now I did notice that at one point, as I was deactivating lots of plugins, that the "double spinning circle" went away and there was just one, which gave me some short-lived encouragement.

    I'm wondering if it's possible that doing a clean re-install of the core WP files would fix this situation.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.