Skip Navigation

[Resolved] Register + Pay = Wrong User type & Custom function Fails

This support ticket is created 6 years, 7 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

Author
Posts
#679355

I am trying to: replicate what we did on a previous site. hidden link
If you see the ticket https://toolset.com/forums/topic/have-a-band-admin-role-to-manage-cpt-band-listing-page/
You guys helped me add a function that took entries from cred Form #1234 and created custom post type. "Wedding Band".

So people could register and a post for their band was created using the name they provided in the form
and they were set as the author.

On a new project, which I started by cloning the weddingbands.ie website,
the site dev.weddingsuppliers.ie has the same cred form
The post type we are creating is a wedding supplier.

We have added Sumo Subscriptions to Charge people for membership.

Link to a page where the issue can be seen:
hidden link

I expected to see:
The membership form completed should result in
1. a subscription
2. A user created and set as Suppliers Applicant
3. A custom post type created named [Supplier-Company-Name]

Instead, I got:
1. The subscription was ok.
2. The user type we are left with is CUSTOMER
3. No Custom Post type has been created.

#679361

I would like to add,

before we added cred commerce, and the additional payment step in teh registration.
The function was correctly handling the new post type and user role.

So the simple cred form would:
1. Create a user with role (Supplier Applicant)
2. Create a CPT (Supplier) using the name given int he cred reg form.

Adding cred commerce has stopped this from working now.

#680225

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi David,

Thank you for contacting our support forum.

I've updated the hook for this and it should work.

Could you try now and let me know if this helps.

Thanks,
Shane

#680561

Hi Shane,

Thanks for the reply,
I just tried a fresh registration and a user was created but as a customer.
The info was taken from the Woocommerce checkout so that's normal I suppose.
And seeing as the billing info was different to the Suppliers info, the billing info was stored as the user and not the cred form data.

Equally, no custom post type was created at all,

#681497

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi David,

I made an attempt with the form again and you an see the post was created for me.

Could you try on your end again and let me know.

Thanks,
Shane

#688227

Hi Shane,
Yes, I See your entries but, what form did you use?

Did you use this?
hidden link

Did you go to a woocommerce checkout and enter Billing Info?

Did you add a test card number for stipe?

Please and thanks

David

#700350

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi David,

Yes this is the form I used.

Would you mind sending me a test card that I can use to complete the payments ?

Thanks,
Shane