VForce Extensions Wordpress Plugin - Rating, Reviews, Demo & Download

VForce Extensions Wordpress Plugin - Rating, Reviews, Demo & Download
No ratings yet
Free
Follow for free plugins, new theme releases and theme news

Plugin Description

Easily manage Vforce integrations through WordPress. Currently supports voting forms and web to case forms through Form Assembly. As well as adding products to a cart through Formidable.

Included Functions

js/init-global.js

This file doesn’t actually do anything. It only exists to be passed into the
php
wp_localize_script()

function along with an array of variables that we would like to be available to every page.

js/formidable/add-to-cart.js

This script allows you to create a formidable form with woocommerce products in a dropdown or radio buttons. Once the user chooses a product and clicks next on the form, the product id is saved in their browser. When they complete the form, an Ajax request is made to add the time to their cart.

js/form-assembly/hide-ballot.js

This script will show/hide a form based on the value of an input with title of Ballot Cast. If that input is found on the page and its value is equal to Cast or cast, then the user will see a custom message instead of the voting form. The message can be customized by going to the plugin settings (Vforce Extensions) and changing the Form Assembly Ballot Message textarea. A default message is included.

In order for this to work properly, please make sure to wrap the form in a div with the class of ballot-container.

E.g.

`html

[formassembly formid=50 server=https://virtual.tfaforms.net]

`

This way the form will be hidden by default and will either appear or show the message when page loads.

js/form-assembly/web-to-case.js

Automatically adds the association id to a Form Assembly contact form embedded on any page. The association id can be set in the plugin settings.

Global Variables

Every page should have access to an object called vforce_helper. This object contains all custom variables from the settings pane.

e.g.

`javascript

vforce_helper
{assocId: “”, faProductSelector: “item_meta[6]”, ballotCastMessage: “”}
`

This is accomplished by passing key/value pairs to the following function in the plugins functions.php file

`php

wp_localize_script( ‘init-global’, ‘vforce_helper’, array(
‘assocId’ => get_option(‘association_id’),
‘faProductSelector’ => get_option(‘form_assembly_product_selector’),
‘ballotCastMessage’ => get_option(‘form_assembly_ballot_message’)
)
`

Screenshots

No screenshots provided


Reviews & Comments