[Closed] How do I create E-Main Subscription Forms?

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.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

This topic contains 7 replies, has 2 voices.

Last updated by Christian Cox 2 years, 5 months ago.

Assigned support staff: Christian Cox.

Author
Posts
#577927

Tell us what you are trying to do?
I want to create "E-Mail Subscription" forms. Similarly like Mailchimp's Subscription box.

Is there any documentation that you are following?
hidden link
Is there a similar example that we can see?
hidden link
What is the link to your site?
(Testing)

Hi, How do I create E-Mail Subscription forms or Opt-in forms with CRED?

#577929

Sorry for the Typo.
The Title of the thread is: "How do I create E-Mail Subscription Forms?'

#577938

Christian Cox
Supporter

Languages: English (English )

Timezone: America/New_York (GMT-04:00)

It depends - do you want to create Users in WordPress for each email address? If so, you will use a CRED New User form. Submitting the form will create a new User in WordPress. You can store a custom checkbox field in each User's profile that indicates their opt-in preference.

If you do not want to create new Users for each email address, then you will use a CRED Edit Post form. First you will create a a custom post type called "Mailing Lists". Create your first Mailing List and save it. Then create a repeating custom email field and apply that field to your Mailing List post type. The the Edit Post form will be used to add values into this custom field for each email address. This will let you capture a list of email addresses and associate it with each Mailing List. You may only have one Mailing List, so that's okay.

Let me know if this helps explain things, or if you need more detailed information about these steps.

#577997

Hi Christian,

I don't want to create users in WordPress. I want to create "E-Mail Opt-in" list.

Can you provide detailed step-by-step for that?

#578007

Christian Cox
Supporter

Languages: English (English )

Timezone: America/New_York (GMT-04:00)

Yes! I can help you create a Mailing List post that includes a custom, repeating field. That repeating field will hold email addresses of all the Users who submit the form. The result will be something like the image I have attached. Just to be clear, Toolset is not an email scheduling and delivery system like MailChimp, and does not help you send email blasts. It can help you store multiple email addresses in a custom field on a custom post. If that's okay with you, here are the steps:

1. Create a new Custom Post Type called "Mailing List". Create a new Mailing List post and call it "Mailing List 1"
2. Create a custom email field called "email" and set it to "allow multiple instances of this field". Associate this Field Group with your Mailing List post type.
3. Create an Edit Post CRED form that edits a specific post - Mailing List 1. Use the CRED form wizard to auto-generate the code for this form. Remove all the inputs from this form except the form_messages field and the submit button. Add a generic email field here called "add-email". This is where your users will enter their email address. Example form:

[credform class='cred-form cred-keep-original']

	[cred_field field='form_messages' value='' class='alert alert-warning']

	[cred_generic_field field='add-email' type='email' class='' urlparam='']
{
"required":1,
"validate_format":1,
"default":""
}
[/cred_generic_field]


	[cred_field field='form_submit' value='Submit' urlparam='' class='btn btn-primary btn-lg' output='bootstrap']

[/credform]

4. Add the following custom code to functions.php:

add_action('cred_save_data', 'add_email_subscription',10,2);
function add_email_subscription($post_id, $form_data)
{
    // if a specific form
    if ($form_data['id']==123)
    {
        if (isset($_POST['add-email']))
        {
            // add it to saved post meta
            add_user_meta($post_id, 'wpcf-email', $_POST['add-email']);
        }
    }
}

5. Replace "123" with the numeric ID of your CRED form, which can be found in the dashboard table at Toolset > Post Forms.

6. Place the CRED form on a page or in a Content Template using the CRED Forms button. Test it out on the front-end. As email addresses are submitted, verify they show up in "Mailing List 1" in wp-admin.

Let me know how it goes.

#578084

Thanks, Christian.

Since I'm completely New to this Toolset application, It is still hard to understand each of the Toolset functionalities. (Very basic level only) A Complete Video walk-through would have better for understanding this setup.

Anyway, I will try the same withe steps you've provided in here.

#578097

I've created the same. But the functionality is not coming as expected. Now what is happening is, whenever a user enters their email ID in the Front-end Mailing list section, it is saving as following in the back-end of mailing list section.

CRED Auto Draft 77c6be92f7wsrw3234873f75e0

What I expected is,

  • To grow my emailing list, I need to create an Opt-in form to collect their "Full Name" and the "E-Mail".
  • Once user entering their Full name and E-Mail details, the form will show a success/failure message.
  • In the back-end the user data "Full Name" and "E-Mail" can be save in a tabulated format with column: SL. No., Full Name, E-Mail ID and Time-stamp.
  • If possible, since it is Opt-in list, Verification Email ID will be sent to a user's email and once it's subscribed the status message will show confirmed/unconfirmed in our custom mailing list form.
  • Similarly we need to create unlimited number of mailing list.

Can anyone provide, Step-by-Step guide for the same? Video guide will be grateful.

Actually it is very difficult for me to understand each and every aspects of Toolset types as I'm in urgent requirement.
If you guys are not helping, for now I may need to use "Contact Form 7" without adding "Verifying the email" part.

#578222

Christian Cox
Supporter

Languages: English (English )

Timezone: America/New_York (GMT-04:00)

Hello, I could take a look in your wp-admin area and make some recommendations if you would like. Please provide login credentials in the private reply fields here.

The topic ‘[Closed] How do I create E-Main Subscription Forms?’ is closed to new replies.