This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action('fluentform_before_insert_submission', function ($insertData, $data, $form) { | |
if($form->id != 17) { // 17 is your form id. Change the 17 with your own login for ID | |
return; | |
} | |
$redirectUrl = home_url(); // You can change the redirect url after successful login | |
if (get_current_user_id()) { // user already registered | |
wp_send_json_success([ | |
'result' => [ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add the JS code to your Forms custom JS section. | |
// Add a container class with the name - max_1_items on your checkbox field. | |
function maxItemsCheck(containerClass, maxChecked) { | |
const checkboxes = document.querySelectorAll('.' + containerClass + ' input'); | |
checkboxes.forEach(function(checkbox) { | |
checkbox.addEventListener('change', function() { | |
const checkedCheckboxes = document.querySelectorAll('.' + containerClass + ' input:checked'); | |
const count = checkedCheckboxes.length; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use FluentForm\Framework\Helpers\ArrayHelper; | |
add_filter('fluentform_validate_input_item_input_number', function ($errorMessage, $field, $formData, $fields, $form) { | |
$fieldName = 'numeric-field'; | |
$target_form_id = 7; | |
if($target_form_id != $form->id){ return $errorMessage; } | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let user_input = $form.find("input[name='custom_payment_input']")[0]; | |
let user_label = $form.find(`label[for='${user_input.id}']`)[0]; | |
// Remove extra stuff in user_label | |
user_label.textContent = "Inscription à prix libre"; | |
// Create new hidden input | |
let hidden_input = document.createElement("input"); | |
hidden_input.type = "hidden"; | |
hidden_input.classList.add("wpf_payment_item"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Add the smartcode to the list | |
*/ | |
add_filter('fluentform_editor_shortcodes', function ($smartCodes) { | |
$smartCodes[0]['shortcodes']['{5_digit_unique_id}'] = 'Unique ID (5 digit)'; | |
return $smartCodes; | |
}); | |
/* | |
* Transform the smartcode |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Insert this codes in your functions.php file | |
add_filter('fluentform_insert_response_data', 'update_url_and_chaturbate_username', 10, 3); | |
function update_url_and_chaturbate_username($formData, $formid, $inputConfigs) | |
{ | |
if($formid != 17) { | |
return $formData; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action('fluentform_before_insert_submission', function ($insertData, $data, $form) { | |
if($form->id != 98) { // 23 is your form id. Change the 23 with your own login for ID | |
return; | |
} | |
$selected_login = \FluentForm\Framework\Helpers\ArrayHelper::get($data, 'input_radio'); | |
if($selected_login == 'Login') { | |
$redirectUrl = home_url(); // You can change the redirect url after successful login |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Add class 'dropzone' to the upload fields that you would like to have this styling | |
*/ | |
.fluentform .dropzone .ff_upload_btn.ff-btn { | |
color: #646c7f; | |
padding: 3rem; | |
width: 100%; | |
border: 2px dashed #0087f7; | |
border-radius: 5px; | |
background: rgba(223, 240, 255, 0.13); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@media (max-width: 1024px) { | |
table.ff_flexible_table tbody tr { | |
display: block; | |
background: #fff; | |
position: relative; | |
border-bottom: 1px solid #ced4da; | |
border-top: 1px solid #ced4da; | |
border-color: #ced4da; | |
border-style: solid; | |
border-width: 2px 1px 4px; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Styles the Radio field as clickable image for Fluent Forms | |
* | |
* Use: Paste into Custom CSS Section of your Form | |
* Add class "fancy-input" to container of all inputs that need the fancy styling | |
* | |
* Forked version of Sebastian Berger from inital post Fluent Forms FB Group - https://bit.ly/37BBpet | |
* FB Post - https://bit.ly/2ZEn2BG | |
* | |
* Full Links at bottom |
NewerOlder