4 Ways You Can Make Your Reps More Productive Today – Download Now

Building a calculator with WP Forms plugin

Building a calculator with WP Forms plugin

One of the great things about WordPress is the great number of amazing plugins that are available to extend/build functionality in any type of website. One such amazing plugin is the WP Forms plugin which is a great plugin to create amazing forms quickly. However, what I really like about this particular plugin is how it provides amazing options to extend its features with the right use of actions and filters.

So when needing to build a customized calculator WP Forms seemed like a great choice. So here is how we built a custom calculator for a client using WP Forms.

Step 1:
Create your form

This is a no-brainer considering how easy it is to create a form using WP Forms. Make sure that whatever fields you want to use for calculation are numbers – this way the validation check are done for you already.

Step 2:
Note the numbers for the fields on which you want to perform calculation.
WPForms Builder - Field Numbers

Step 3:
Find out the id for the form.
WPForms Builder - Form ID

Step 4:
Add this bit of code in your site (usually the functions.php file)
https://gist.github.com/speedguy/672dc22f2e30c2b21ced97a4dcc1e338

Advantages of this approach

  • You can use the validation methods that already come built inside WP Forms
  • Entries are stored at the backend for later reference (you can even export these as a csv)
  • Email is sent with the form data – it can be customized to show the form calculation result as well (not covered in this example)
  • Using the Pro version of the plugin you can actually build a multi page/part calculator where data is gathered over multiple steps and then processed at the end

Click Here For Demo

* Note that the version we used is the pro version which has some features available that are unavailable in the free version (such as multi-page conditional forms) – but effectively the idea is the same. You can build multi-step conditional forms that perform complex calculations using this method.

Why a good “call to action” is necessary for your website

Why a good “call to action” is necessary for your website

A website is the equivalent of having an office/shop on the internet. Just as every shop needs a sign board outside telling everyone the name of the shop and what you can get here a website too needs some sort of signboard. That signboard is really what you can call the header of your website and must contain what is called a “call to action”.

Some cool ideas for call to action are listed below. But really you are not limited by your imagination and can do something fancy specific to your website/business.
Phone Number
This is great for websites where you want the visitor to call you up for further details.

Email
If you want people to email you straight away then this might be a great idea (be aware that plain email is very likely to also attract spam)

Popup form
This is by far my favorite. A small phrase to get the interest of the visitor results in a click which opens a popup that shows a contact form. This allows the site owner to get a couple of fields from the user or maybe even have the visitor opt in to a mailing list.

Sticky button
This can be a button that sticks to the top or an edge of the browser and stays there even if you scroll through the website. The fact that it is always visible means that your visitor can take the action even if they are halfway through the page.