• Skip to main content
  • Account
  • Announcements
  • Contact

RSVP Pro Plugin

Easy RSVP and Event Management for WordPress

  • Features
  • Documentation
  • Use Cases
  • Pricing

RSVP Pro Plugin

November 22, 2018 By Cristian

New RSVP Pro Attendee Import Workflow

One of the frequent support requests I receive for the RSVP Pro plugin is questions surrounding the attendee import functionality. When the import process was created eight(!) years ago. You had to have a specific file layout in your spreadsheet, and it was rather fragile. The import process was way overdue for an overhaul.

With the release of version 3.8.7 the import process is much easier to use. Here is a video showing the new workflow when importing attendees.

With the new process as long as you have your attendee information in a CSV or Excel file, you can import it into your event. The only required field is either a first OR last name. You can read more details in the updated documentation.

I hope it improves your the workflow. If you have any feedback, please contact me. I love to hear from my users.

Filed Under: RSVP Pro Plugin

October 18, 2018 By Cristian

Sending Inline Images via WordPress’ WP_Mail

Recently I was implementing the ability to send QR codes in the RSVP confirmation emails. While doing that I ran into a stumbling block on how to send attachments inline. Since there didn’t seem to be any good documentation on how to do this minus some StackOverflow posts, I thought I would share how I did it and the lessons I learned in regards to sending images as emails in WordPress.

The First Attempt

Initially, when implementing this feature, I tried to do a base64-encoded image inline with the email. However, that wouldn’t show up when the email was viewed in Gmail’s web interface. So, I kept that there and also attached the QR code at the bottom of the email as well. That worked but was pretty ugly as that meant every email with QR shortcodes had at least two QR codes in it. That would be pretty confusing for both attendees and people working events.

Inline Attachments to the Rescue

To fix this I went with inline attachments. The only problem with this and the reason I didn’t do it this way in the first place is that there was no good documentation on how to do this. Especially when you were sending out many different emails. Below is, in general, the solution I came up with which worked for my use-case. Hopefully, it can be useful to some other person as well.
In my case, the code, that sends the email is separated from the part of the code that prepares the email body for sending. To get around this, I used a global array in my plugin to temporarily store the images I wanted to inline attach. If there was one object that was just being passed around, I would have stored the information in there, but that is currently not the case for my code base. I secondly created a wrapper around the wp_mail function which we will use later to implement the inline attachments. Below is the starting of the wrapper:
function example_send_mail( $email, $subject, $body, $headers = '', $attachments = array() ) {
    wp_mail( $email, $subject, $body, $headers, $attachments );
}
I then went through my code and replaced all of the calls to wp_mail with this new wrapper function. One thing I made sure to do with the wrapper is to use the exact same parameter ordering and defaults as wp_mail, so it was simple to swap.
Once I had that in place, it was now time for me to get inline attachments working. This was broken up into two separate pieces of work:
  • Email body generation
  • Attaching the files to the email right before it sends

Generating Content

While generating content for the email I would check to see if an inline image was needed. If needed I would create the image and then add it to the global array with the following attributes:
  • uid: A unique identifier that is used for inline attachments this needs to be referenced to inline attach the image
  • name: The name of the attachment that the user will see
  • file: The path to the file that needs to be attached
The code looked something like.
$uid                     = uniqid();
$name                 = 'Inline Image.png';
$file_path            = generate_and_save_image();
$inline_attachments[] = array(
    'uid'  => $uid,
    'name' => $name,
    'file' => $file_path,
);
We then use the $uid variable for the inline image in the body of the email.
$body .= '<img src="cid:' . $uid . '" />'

Basically, the email clients see the “cid” and try to find an attachment with that ID and then shows it inline.

Attaching the Images to the Email

Now that the content has been generated we need to go back to the wrapper function we wrote earlier and attach the images to the email.
To do this, we will want to add an action with a function to embed the image. It looks like.
add_action( 'phpmailer_init', function( &$phpmailer ) use( $inline_attachments ) {
    $phpmailer->SMTPKeepAlive=true;
    foreach ( $inline_attachments as $a ) {
        $phpmailer->AddEmbeddedImage( $a['file'], $a['uid'], $a['name'] );
    }
});
What this function does is adds an embedded image with the attributes we specified when we were creating the email content. We want to do this before the wp_mail function is called. After the wp_mail function is called, we want to clean-up the images that we generated as well. Here is roughly what I wrote.
foreach ( $inline_attachments as $a ) {
    if ( file_exists( $a['name'] ) ) {
        unlink( $a['name'] );
    }
}
This is what the finished wrapper function looks like.
/**
 * Example wrapper for sending email. This is used to allow for
 * inline attachments, etc...
 *
 * @param string $email The email address we want to send the email to.
 * @param string $subject The subject for the email.
 * @param string $body The body of the email.
 * @param array  $headers The headers for the email.
 * @param array  $attachments The attachments for the email.
 */
function example_send_mail( $email, $subject, $body, $headers = '', $attachments = array() ) {
    global $inline_attachments;

    add_action( 'phpmailer_init', function( &$phpmailer ) use( $inline_attachments ) {
        $phpmailer->SMTPKeepAlive=true;
        foreach ( $inline_attachments as $a ) {
            $phpmailer->AddEmbeddedImage( $a['file'], $a['uid'], $a['name'] );
        }
    });
    wp_mail( $email, $subject, $body, $headers, $attachments );

    foreach ( $inline_attachments as $a ) {
        if ( file_exists( $a['name'] ) ) {
            unlink( $a['name'] );
        }
    }
    $inline_attachments = array();
}
That is it. I hope this is helpful to others and provides an example of how you can embed an inline attachment with WordPress.

Filed Under: Misc, RSVP Pro Plugin

October 14, 2015 By Cristian

RSVP Pro’s 1st Birthday

One year ago today (10/13/2014) I released RSVP Pro to the world. Since it has been a year I wanted to reflect on the good and bad. First some statistics:

  • 82 releases since this year
  • ~130 customers

I am pretty happy with both of these since there have been zero marketing efforts except for a link or two from the free version of the plugin. Thanks to many of my customers in giving me feedback and reporting issues. It always amazes me at the different ways people can use a product.

The Good

So many more new features have been released this year than I thought would happen. As more and more people used the plugin and gave me feedback it was important for me to deliver the functionality to let people have a successful event. Some of the larger features that were added after the initial release are:

  • An optional wizard like front-end user experience
  • Ability to easily email all or selected attendees
  • Sub-events including open and private events

The Bad

There wasn’t anything specifically bad that happened. The only thing that was “bad” was I hoped for more sales and sales to pick-up “magically” that is my own fault. It still sucks though :).

What is ahead?

Many things! To summarize though I want to finish up my ideas on how to make the RSVP Pro plugin easier to use and I am going to focus a little bit on marketing to help build an audience. My goals is to make this the easiest to use and full-featured event management or RSVP plugin for WordPress.

 

Filed Under: RSVP Pro Plugin

September 19, 2015 By Cristian

Multi-site license vs. Single license

One fairly common use case for the RSVP Pro plugin is for event management and wedding companies to offer the plugin in a white label fashion. An easy way to do this is by enabling a WordPress Network (aka a multi-site instance), however, until recently the user experience was not the best in this case. Depending on how you wanted to look at it you were installing it on a single instance, however, you would get an error that the license was invalid. The multi-site license is a way to fix this so the error goes away and it continues to work better in a network.

Now when you install the pro version of the plugin and network activate it you can specify the license in the network admin section. As long as you have a multi-site license everything will validate correctly and no more invalid license messages will appear.

What happens if you install the pro plugin on just one blog in a network with a single-site license? It will operate just like you would have if you had installed it on a standalone WordPress instance as it should.

The other use case for a multi-site license is if you are a consulting shop that is going to end up using it on more than nine sites and so instead of doing multiple purchases you can just purchase it once and use the same license key for all of the sites.

Filed Under: RSVP Pro Plugin, Uncategorized

June 30, 2015 By Cristian

Max Attendees and Waitlist Functionality

The RSVP Pro plugin was just released with a few more features that have been asked for recently. These features are the ability to set a max attendee limit and also to have a wait list. These two options can be found under each event’s general setting tab. A screen capture of the two options is shown below.

max_guest_wailist_option

The option, “Max guest limit for event,” is used to specify a guest limit it can be left blank and it is assumed there is no limit. Any positive non-zero number can be used for the guest limit. When a guest tries to be added and the limit is hit either a message will appear or they will show as having RSVP’d as “No.”

The option, “Allow for a wait list,” is used to enable the wait list. If a user tries to RSVP and the event is already at maximum capacity they can choose to say no or to be added to the wait list.

Besides these two main options there are also related text formatting options under the “text customizations” tab.

waitlist_text_customization

How did these features help you in your event? We would love to hear about it.

Does the RSVP Pro plugin not exactly fit what you need? Please get in touch and we will see what we can do for you.

Filed Under: RSVP Pro Plugin

  • Page 1
  • Page 2
  • Go to Next Page »
  • Account
  • Announcements
  • Contact

A MachoThemes Product