JS query problem

Hi There,

I am having problem getting the Add billing Method to kick in.

I get a
Uncaught ReferenceError: jQuery is not defined
at s2member-o.php?ws_plugin__s2member_js_w_globals=1&qcABC=1&ver=170722-170722-4083727301:1

Any idea what would be causing this?

thanks,
ref: https://englishconfidenceunlocked.com/product-a/

Hi Andrew.

I’d suspect a plugin conflict… Could you please follow the advice in this article? https://s2member.com/kb-article/common-troubleshooting-tips/

This plugin may help: https://wordpress.org/plugins/health-check/

Let me know how it goes. :slight_smile:

I installed the plugin you recommended.
Everything but the core elements were disabled ( Theme/WooC/Stripe/S2 left)

Problem persists…

What now?

Leave only s2 in your tests and see if you get the problem with just s2 in a default WP.

If the problem is gone, then add the others one by one, testing after each if the problem comes back. Then you’ll be able to tell which one is conflicting.

Maybe something you’re using may be making jQuery load later, after s2Member actually tries using it…

s2Member Pro doesn’t have that problem by itself, or normally with other plugins, or I’d have had it reported often. Something is introducing the issue in your particular installation, and that’s what we’re investigating following these troubleshooting steps.

:slight_smile:

Thanks Cristian.

However it makes no sense to me. Maybe its’s just me!
If I only activate S2 how can it process payments - without having a payment gateway etc installed

s2Member includes the payment gateway integration. In the s2Member Framework is just PayPal Standard, but s2Member Pro adds Stripe and a few more.

I see from what you said earlier that you use Stripe. s2Member Pro already includes it. If you can’t find it in the navigation, make sure you activate it first from WP Admin > s2Member Pro > Other Gateways

You’re using the Stripe Pro-Form in that page, so you can see it in the navigation, so the gateway is enabled in your s2Member Pro already. Then you can configure the integration with it from WP Admin > s2Member Pro > Stripe Options

Why do you feel you need another plugin for s2 to work with Stripe? Are you doing it to get some extra feature? I’m trying to understand better what you have set up.

I look forward to your update. :slight_smile:

Thanks.

I did what you suggested…just S2

No change…

I sell various products…they are set up in WooC

Thanks for the update.

So you did all these tests with the Health Check plugin, right?

Would it be possible for me to see your site and the admin area? You can message me privately for this.

Yes I disabled all but S2…the page you can check on is
https://englishconfidenceunlocked.com/product-a/

HI Cristian

I am looking forward to your update.

cheers

Your jQuery is not defined even on the home page… Switch the theme to “2017” and test again, I think this is because of the theme.

I tried that.

No change.

If there is a WP theme issue, doesn’t sound good ( from my limited understanding)

Any suggestions?

When you change the theme, was there a problem with jQuery at home page? Find a theme without problems and test s2M on it.

I have no idea how to check that.

I will say though that if s2Member is not working with a default WP theme there is a bigger issue.
Maybe a clean reinstall of my site would solve the problem. But that seems like a real big deal…to me.

Even if I find a theme that will work, I am using Thrive themes. It MUST work with that. Having it work with some WP theme is clearly not good enough.

Is there a way to work this out?

Hi Andrew. Thanks for your patience.

I looked closer at your page and with a bit of digging found that jQuery is being loaded, but it seems to be a bit after s2Member tries to use it.

I will look some more to confirm that that’s the case, and then find how to change the order in which they’re loaded, and will get back to you with an update. :slight_smile:

Many thanks Cristian

1 Like

I can’t find yet why jQuery is being loaded after s2Member’s JS, if s2’s is being queued properly and saying it requires jQuery… I haven’t studied the theme’s code to find what it’s doing that causes this, but it doesn’t matter, because I know it’d be a pain for you to change theme, so I want to find a way around it.

I’d like to try a couple of plugins that’d let one alter the order in which the JS is loaded, but I don’t want to do it in your live site, and my sites don’t have this issue to see if I can fix it. Would it be possible for you to create a clone of your site to test this? Or at least a backup that you can go back to if needed, and I tell you what plugins to try if you want.

:slight_smile:

Appreciate your care and attention to this Cristian.

I have had a look at cloning. I can’t do it from the CP it seems so it would need a download …SETup aND reload. Not sure if my skills will not blow out the time to do all this/(set up stage).:worried: :slight_smile:
So I have backed up site. At the moment, its a low use site, so I ma not overly concerned. So pls do what you can with the site as it is.

many thanks again

1 Like

any progress Cristian?