Skip to content

Instantly share code, notes, and snippets.

View reachkamrul's full-sized avatar
😁

Md Kamrul Islam reachkamrul

😁
View GitHub Profile
// Math summation on columns
var myClasses= "column_one, column_two, column_three"; //give your columns key, you can use multiple by using comma
var totalText = "Total: "; // you can change the 'Total' text here
if(!$table.find('tfoot').length){
jQuery("<tfoot></tfoot>").appendTo($table);
}
$shortcodeDefaults = apply_filters('fluentform_info_shortcode_defaults', array(
'id' => null, // This is the form id
'info' => 'submission_count', // submission_count | created_at | updated_at | payment_total
'status' => 'all', // get submission count of a particular entry status favourites | unread | read
'with_trashed' => 'no', // yes | no
'substract_from' => 0, // [fluentform_info id="2" info="submission_count" substract_from="20"]
'hide_on_zero' => 'no',
'payment_status' => 'paid', // paid | all | pending | failed
'currency_formatted' => 'yes',
'date_format' => ''
var passField = $form.find('input[data-name=password]');
passField.wrap("<div class='ff_input-group'></div>");
passField.after('<div class="ff_input-group-append"><span class="ff_input-group-text"><i style="cursor:pointer;" class="dashicons dashicons-hidden toggle-password"> </i></span></div>');
$form.find(".toggle-password").click(function() {
$(this).toggleClass("dashicons-visibility dashicons-hidden");
if (passField.attr("type") == "password") {
passField.attr("type", "text");
} else {
@reachkamrul
reachkamrul / wff-custom-css.css
Last active May 8, 2023 11:16
WP Fluent Forms Custom CSS
/* Change button style*/
form.fluent_form_149 .ff-btn-submit {
background-color: #000000; /* change button background color */
color: #ffffff; /*change button font color*/
border-radius: 10px; /*change button round corners*/
}
/*Change button hover style*/
form.fluent_form_149 .ff-btn-submit:hover {
/*
* The following functions will add additional file types option to your file upload element
* In this case, You can enable STL, MAX, DWG, STEP, OBJ, FBX, Ect file format
* Just add this snippet to your theme's functions.php file or relevant place.
*/
add_filter('fluentform_file_type_options', function ($types) {
$types[] = [
'label' => __('3d files - DWG, STL, STEP, STP, SKP, MAX, FBX, 3DS, IGES, IGS, OBJ', 'fluentform'),
'value' => 'dwg|stp|stl|STEP|skp|max|fbx|3ds|iges|igs|obj',
$(document).ready(function(){
var myData = jQuery('.foo-table td.from').text();
jQuery('.fluentform input.to').val(myData);
// jQuery('.fluentform input.to').attr('readonly','1');
})
<?php
/**
*
* ***** WooCommerce Purchase Validate Addon for Fluent Form *****
*
* Subscription status file
*
* @package wpvafff
*/
$urlValue = 'http://google.com/?url=';
$fieldName = 'url';
$form.find('input[name="'+$fieldName+'"]').on('change, keyup', function($fieldValue){
$fieldValue = jQuery(this).val();
$url = $urlValue+$fieldValue;
$form.on('fluentform_submission_success', function(){
window.open($url, 'name');
});
/*
* Custom Editor SmartCode
* {my_http_refer}
*/
add_filter('fluentform_editor_shortcode_callback_my_http_refer', function ($val) {
return 'My Value';
});