• Resolved alpha1beta

    (@alpha1beta)


    Same problem on two sites, including a fresh install, cannot create a new gravity form due to a JS error. While I have other plugins enabled, disabling awesome support alone removed the problem.

    Firefox console says TypeError: $(...).wpColorPicker is not a function
    and points me to this code in the footer

    jQuery(document).ready(function($) {
    	"use strict";
    	$('.tf-colorpicker').wpColorPicker();
    });

    This script should probably only show up on Awesome support pages, where the color picker is included.

    https://www.ads-software.com/plugins/awesome-support/

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author julien731

    (@julien731)

    Hi,

    This is a conflict with the Titan Framework that we use for managing plugin options. However, this bug should have been fixed in a prior version. Could you please confirm which version of Awesome Support you’re using?

    Thread Starter alpha1beta

    (@alpha1beta)

    Fresh installs from the plugin repo, 3.2.9

    Plugin Author julien731

    (@julien731)

    If @bfintal is around: have you heard of conflicts between TF and Gravity Forms?

    In case anyone is still trying to resolve this, the file in question that is causing trouble is: ~/wp-content/plugins/awesome-support/vendor/gambitph/titan-framework/lib/class-option-color.php

    As a workaround, in this file, I’ve changed the code found around 76, which should be:

    jQuery(document).ready(function($) {
    	"use strict";
    	$('.tf-colorpicker').wpColorPicker();
    });

    to:

    jQuery(document).ready(function($) {
    	if ($('.tf-colorpicker').length) {
    		"use strict";
    		$('.tf-colorpicker').wpColorPicker();
    	};
    });
    Plugin Author siamkreative

    (@siamkreative)

    I’m unable to replicate this issue with AS 3.2.9 and Gravity Forms 1.9.6.

    But thanks anyway! Bare in mind that every time there’s a plugin update the edit will be gone…

    I was also having this problem and can confirm that dornstudio’s fix above works perfectly.
    I would recommend that the authors of this fine plugin merge their suggestion into the core plugin.

    Jack

    I had same issue however code mentioned above didn’t work for me! So, I went to the Titan-Framework page over at GitHub and found the working update:

    	/**
    	 * Load the javascript to init the colorpicker
    	 *
    	 * @since 1.9
    	 *
    	 * @return void
    	 */
    	public function startColorPicker() {
    		?>
    		<script>
    		jQuery(document).ready(function() {
    			'use strict';
    			if ( typeof jQuery.fn.wpColorPicker !== 'undefined' ) {
    				jQuery('.tf-colorpicker').wpColorPicker();
    			}
    		});
    		</script>
    		<?php
    	}

    You guys may want to look at updating the version of Titan-Framework you are using in the plugin, it’s outdated!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Conflict with Gravity Forms’ is closed to new replies.