CodePeople2
Forum Replies Created
-
Hello @cambob
Actually you don’t need using “IF” operations in this case, you can do it with the MIN and MAX operations:
MIN(MAX(fieldname11, -1), 1)However, if you want to embed IF operations, you can implement the equation as follows:
IF(fieldname11<-1, -1, IF(1<fieldname11, 1, fieldname11))Note I embedded another IF operation as an operand of the first one.
Best regards.
Hello @spacemakerman
Please do not enclose the field’s name between single or double quotes. In the equation context, the plugin knows you are referring to the field’s name because you used the |n modifier. So, the equation would be:
(function() {
var dropdown = getField(fieldname5|n).jQueryRef().find('select');
dropdown.find('option:eq(2)').val(fieldname1);
return fieldname1;
})();Best regards.
Hello @spacemakerman
I’m sorry, I don’t understand what you mean by “dynamically pass a value from a field to a specific selector position within a single form”.
Do you want to change the value of a specific choice?
If it is the case, and you want to change the value of the third choice in the checkbox field fieldname123, you can insert a calculated field in the form as an auxiliary (you can hide it by ticking a checkbox in its settings), and enter the equation:
getField(fieldname123|n).jQueryRef().find('[type="checkbox"]:eq(2)').val(444);Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingHello @pexel
We’ve contacted WP Rocket and are awaiting their response. If you need personalized technical support, please visit the plugin’s website and contact us directly. Contact Us.
Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingForum: Plugins
In reply to: [Calculated Fields Form] Data Transfer to Popup from Buttons in CFFHello @spacemakerman
In this case, please edit it as follows:
<script>
fbuilderjQuery(document).on('click', function(evt){
let e = fbuilderjQuery(evt.target);
if( ! e.hasClass('.cff-popup-container') && ! e.closest('.cff-popup-container,.cff-button-field').length) fbuilderjQuery('.cff-popup-field').addClass('hide-strong');
});
</script>Or the buttons onclick events as follows:
fbuilderjQuery('.my-form .cff-popup-field').removeClass('hide-strong').show();Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingForum: Plugins
In reply to: [Calculated Fields Form] Problem with displaying elements in CFF editorHello @spacemakerman
I apologize for the inconvenience and thank you for providing the additional details. We have found the issue, it is related to the “Autocomplete” complementary plugin and released an update for the autocomplete plugin to fix it. Please install the latest update of the Autocomplete plugin and purge the website and browser caches.
Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingHello @pexel
That question is best directed to the WP Rocket support team. I have recommended the solutions within our plugin for such cases:
• Use the iframe attribute in the form shortcode.
• Exclude the page containing the form from the WP Rocket cache.Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingHello @pexel
No, the plugin does not work in that way. The form is rendered on the client side, but the form tag is added to the page’s source on the server. If the source page does not contain the form tag the issue is not related to the JS or CSS files. Your website is not reaching even our plugin code.
Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingHello @pexel
Thank you very much for the clarification. However, if you examine the provided source code, it does not even include the
<form></form>tag corresponding to our plugin. This can only occur if the page does not contain a form shortcode, or if your website loads a cached version before the form’s insertion (likely because you are pulling it from an outdated CDN server).Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Form not loadingHello @pexel
If you check the source provided, you will detect it does not include even the form tag of our plugin, the only reference to our plugin is:
<textarea id="pexpe-iframe-code" style="width: 100%; height: 100px; margin-top: 30px;" readonly><!-- PEXPE.COM, Kolay ve Hızlı Hesaplama --><a href="https://www.pexpe.com/gunluk-makro-besin-hesaplama/" target="_blank"><img src="https://www.pexpe.com/back.png" alt="Günlük Makro Besin Hesaplama" style="width: 215px; height: 12px; float: right; margin-bottom:-5px;"></a><iframe id="pexpe" src="https://www.pexpe.com/?cff-form=369&template=cp_cff_custom" style="width:100%; height:470px; overflow: hidden; border: none;" scrolling="no"></iframe><script>let iframe=document.getElementById("pexpe");window.addEventListener("message",function(e){let message=e.data;iframe.style.height=message.height+20+"px";},false);</script><!-- PEXPE.COM, Kolay ve Hızlı Hesaplama --></textarea>It has intercepted the iframe tag, and has loaded it into a textarea. I’m sorry, but this issue is not related to our plugin.
Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Data Transfer to Popup from Buttons in CFFHello @spacemakerman
Please replace the piece of code:
fbuilderjQuery('.my-form .cff-popup-field').show();With this one:
fbuilderjQuery('.my-form .cff-popup-field').removeClass('hide-strong');Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Problem with displaying elements in CFF editorHello @spacemakerman
The issue you are reporting is usually related to a downgrade. Have you been using the Developer or Platinum plugin distribution?
Best regards.
Forum: Plugins
In reply to: [Calculated Fields Form] Data Transfer to Popup from Buttons in CFFHello @spacemakerman
First, assign a custom class name to Form 4, you can do it by passing the class attribute through the form’s shortcode. E.g.
[CP_CALCULATED_FIELDS id="123" class="my-form"]Assuming the field in the pop up that you want to fill by pressing the button is the fieldname456.
For example, if you want to populate the fieldname456 field in the popup with the value of the fieldname12 field and open the popup by pressing the button in Form 1. The onclick event would be similar to:
getField('fieldname456', '.my-form').setVal(getField('fieldname12', this.form).val(true, true));
fbuilderjQuery('.my-form .cff-popup-field').show();Best regards.