latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Conditional select field for multiple forms?

Home Forums Community Forum Conditional select field for multiple forms?

This topic contains 4 replies, has 2 voices. Last updated by  Jp Realey 3 years, 2 months ago.

Topic Author Topic
Posted: Friday Oct 25th, 2013 at 5:19 pm #60614
Jp Realey
Username: pixedoodle

Hi everyone
I want to have a select field on my registration page, a drop down asking the member if they want level #1, #2 or #3 (monthly access, 3-monthly access or annual access). The idea of this was to just use one registration form.

I have just read a forum post saying that S2 allows custom registration fields ie drop down boxes but there is no way to determine the level of access depending on the selection of the drop down box. Im not sure how old that forum post was, is this still the case?

If so, the other option I have is to have my 3 registration forms (for level #1, level #2 and level #3) then code in to the page a drop down box for each level. The idea of this is to code in that if level #1 is selected, do the shortcode to display level #1 form, else if level #2 is selected, show the registration form for level #2 else if level #3 is selected, show the registration form for level #3.

Is this my only other option and if so, any idea on the coding/logic to make this happen?

Thanks.

List Of Topic Replies

Viewing 4 replies - 1 through 4 (of 4 total)
Author Replies
Author Replies
Posted: Saturday Oct 26th, 2013 at 9:31 am #60640
cassel
Username: cassel

Could you consider having like three buttons that are simply redirecting to 3 different pages where the appropriate form will be displayed? That would only mean one extra click for the user.

There might be a way with a drop down or something but I have never used it so I am only mentioning something I am familiar with. Maybe someone else can give you other information too do things with only the dropdown.

Posted: Saturday Oct 26th, 2013 at 10:25 am #60643
Jp Realey
Username: pixedoodle

I had considered that but then it sort of defeats the object of buying the pro version of S2 to integrate the form in to the one page, I dont want the user to have to go to another page.

I have also considered having 3 buttons like you mentioned but instead of having them linked to another page, use jquery to make them show/hide the forms, so all 3 forms would be on the page but hidden, and clicking each button would make the relevant form appear…

That could work…

Posted: Saturday Oct 26th, 2013 at 10:31 am #60644
cassel
Username: cassel

Again, I do not have a definite answer, but I don’t know if you can “code” three forms into a single page. I know you cannot display more than one form, but I don’t know if you can have ONE displayed and TWO hidden on the same page.

If you can find the answer to that, please report here with your solution so others might be able to use the same setting.

Posted: Saturday Oct 26th, 2013 at 10:54 am #60645
Jp Realey
Username: pixedoodle

I have an answer for you.

You can code 3 S2member pro forms in to your page template using the do_shortcode function, as long as only one (or none) is displayed at any one time using display: none;

I then have 3 images for the different levels of membership to act as buttons.

Using jquery, and with all 3 forms initially hidden, I can use jquery show/hide to toggle which form is shown/hidden depending on what image/button is clicked.

Viewing 4 replies - 1 through 4 (of 4 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.