Commit 9bf47f36 authored by Kevin Stover's avatar Kevin Stover

Merge branch 'release/v2.9.1'

parents 64aadb2f a455329f
......@@ -944,11 +944,6 @@ function nf_get_form_count() {
return count( $forms );
}
/**
* Old Ninja Forms shortcode
*/
add_shortcode( 'ninja_forms_display_form', 'ninja_forms_shortcode' );
/**
* Old update form function.
*
......
......@@ -69,9 +69,6 @@ add_action( 'wp_head', 'ninja_forms_clear_transient' );
function ninja_forms_page_append_check(){
global $post, $ninja_forms_append_page_form_id;
if(is_array($ninja_forms_append_page_form_id)){
unset($ninja_forms_append_page_form_id);
}
if(!isset($ninja_forms_append_page_form_id)){
$ninja_forms_append_page_form_id = array();
}
......@@ -92,9 +89,10 @@ add_action('wp_head', 'ninja_forms_page_append_check');
function ninja_forms_append_to_page($content){
global $ninja_forms_append_page_form_id;
if( !is_admin() AND is_main_query() AND ( is_page() OR is_single() ) ){
if( !is_admin() && is_main_query() && ( is_page() OR is_single() ) ){
$form = '';
if(is_array($ninja_forms_append_page_form_id) AND !empty($ninja_forms_append_page_form_id)){
if(is_array($ninja_forms_append_page_form_id) && !empty($ninja_forms_append_page_form_id)){
foreach($ninja_forms_append_page_form_id as $form_id){
$form .= ninja_forms_return_echo('ninja_forms_display_form', $form_id);
}
......
......@@ -287,6 +287,8 @@ function ninja_forms_field_text_display( $field_id, $data, $form_id = '' ){
$disabled = '';
}
$placeholder = isset ( $data['placeholder'] ) ? $data['placeholder'] : '';
?>
<input id="ninja_forms_field_<?php echo $field_id;?>" data-mask="<?php echo $mask;?>" data-input-limit="<?php echo $input_limit;?>" data-input-limit-type="<?php echo $input_limit_type;?>" data-input-limit-msg="<?php echo $input_limit_msg;?>" name="ninja_forms_field_<?php echo $field_id;?>" type="text" placeholder="<?php echo $placeholder;?>" class="<?php echo $field_class;?> <?php echo $mask_class;?>" value="<?php echo $default_value;?>" rel="<?php echo $field_id;?>" <?php echo $disabled; ?> <?php echo $autocomplete_off; ?> />
<?php
......
......@@ -18,6 +18,10 @@ function ninja_forms_shortcode( $atts ){
add_shortcode( 'ninja_forms', 'ninja_forms_shortcode' );
add_shortcode( 'ninja_form', 'ninja_forms_shortcode' );
/**
* Old Ninja Forms shortcode
*/
add_shortcode( 'ninja_forms_display_form', 'ninja_forms_shortcode' );
function ninja_forms_field_shortcode( $atts ){
global $ninja_forms_processing;
......
......@@ -3,7 +3,7 @@
Plugin Name: Ninja Forms
Plugin URI: http://ninjaforms.com/
Description: Ninja Forms is a webform builder with unparalleled ease of use and features.
Version: 2.9
Version: 2.9.1
Author: The WP Ninjas
Author URI: http://ninjaforms.com
Text Domain: ninja-forms
......@@ -284,7 +284,7 @@ class Ninja_Forms {
// Plugin version
if ( ! defined( 'NF_PLUGIN_VERSION' ) )
define( 'NF_PLUGIN_VERSION', '2.9' );
define( 'NF_PLUGIN_VERSION', '2.9.1' );
// Plugin Folder Path
if ( ! defined( 'NF_PLUGIN_DIR' ) )
......
......@@ -3,7 +3,7 @@ Contributors: wpninjasllc, kstover, jameslaws, wpnzach, daveshine, mordauk, bftr
Tags: form, forms, contact form, custom form, form builder, form creator, form manager, form creation, contact forms, custom forms, forms builder, forms creator, forms manager, forms creation, form administration,
Requires at least: 3.8
Tested up to: 4.1.1
Stable tag: 2.9
Stable tag: 2.9.1
License: GPLv2 or later
Forms created with a simple drag and drop interface. Contact forms, Email collection forms, or any other form you want on your WordPress site.
......@@ -66,15 +66,15 @@ This section describes how to install the plugin and get it working.
2. Activate the plugin through the 'Plugins' menu in WordPress
3. Visit the 'Forms' menu item in your admin sidebar
Shortcodes have been re-implemented. They are used like so: [ninja_forms_display_form id=3] where 3 is the ID number of the form you want to display.
Shortcodes have been re-implemented. They are used like so: [ninja_form id=3] where 3 is the ID number of the form you want to display.
== Use ==
For help and video tutorials, please visit our website: [Ninja Forms Documentation](http://ninjaforms.com/documentation/)
For help and video tutorials, please visit our website: [Ninja Forms Documentation](http://docs.ninjaforms.com/)
== Upgrade Notice ==
= 2.9 (3 March 2015) =
= 2.9.1 (3 March 2015) =
*Changes:*
......@@ -84,6 +84,8 @@ For help and video tutorials, please visit our website: [Ninja Forms Documentati
*Bugs:*
* Fixed a bug that could cause a PHP notice to show in placeholders.
* Fixed a bug that could cause forms not to display properly when added via the "append to page" option.
* Fixed a major bug that could prevent longer forms from saving properly. Previous fixes required modifying a php.ini file.
* Creating a new action should now show the proper saved message.
* Updated the Ninja Forms translation file with several new strings and cleaned up existing strings.
......@@ -96,6 +98,13 @@ If you have any feature requests, please feel free to visit [ninjaforms.com](htt
== Changelog ==
= 2.9.1 (3 March 2015 ) =
*Bugs:*
* Fixed a bug that could cause a PHP notice to show in placeholders.
* Fixed a bug that could cause forms not to display properly when added via the "append to page" option.
= 2.9 (3 March 2015) =
*Changes:*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment