p.castaldi
Forum Replies Created
-
Forum: Plugins
In reply to: [Contact Form 7] Moving Submit Button InlineSorry, I did not understand you wanted centered items. You can’t use float: center (it doesn’t exist). You have to do:
ul.floatLi li {display: inline-block; margin-right: 10px;} ul.floatLi li:last-of-type {margin-right: 0px; clear: right;} ul.selfClearCont { text-align: center; padding: 0 !important; margin: 0 !important; } ul.selfClearCont li { list-style-type: none; padding: 0 0 10px 0 !important; } .selfClearCont:before, .selfClearCont:after { content:""; display:table; } .selfClearCont:after { clear:both; } .selfClearCont { zoom:1; /* For IE 6/7 (trigger hasLayout) */ }I did not test it out, but this should work.
Forum: Plugins
In reply to: [Contact Form 7] Moving Submit Button Inlinedo like this:
<ul class="floatLi selfClearCont"> <li><fieldset>[text* your-name placeholder "You Name"]<fieldset></li> <li>[submit class:button_submit "Submit"]</li> </ul>and
ul.floatLi li {float: left; margin-right: 10px;} ul.floatLi li:last-of-type {margin-right: 0px; clear: right;} ul.selfClearCont { padding: 0 !important; margin: 0 !important; } ul.selfClearCont li { list-style-type: none; padding: 0 0 10px 0 !important; } .selfClearCont:before, .selfClearCont:after { content:""; display:table; } .selfClearCont:after { clear:both; } .selfClearCont { zoom:1; /* For IE 6/7 (trigger hasLayout) */ }This should help
Forum: Plugins
In reply to: [Contact Form 7] Loading additional scripts for CF7I noticed a couple of typos, and fixed them.
Now my code is:
function wpcf7_loadConditions($wpcf7_data) { $formId = $wpcf7_data->id(); if (is_null($formId) ) {return;} $myBaseURL = get_stylesheet_directory_uri() . '/js/form/'; /* Conditions for all forms */ wp_enqueue_script('CondAll', $myBaseURL . 'CondAll.js', array('jquery')); /* END of conditions for all forms */ /* Conditions for multiple forms selected by their id */ if ( in_array($formId, array(290,295,316,319)) ) { wp_enqueue_script('CondShipping', $myBaseURL . 'CondShipping.js', array('jquery')); } /* END of conditions for multiple forms selected by their id */ /* Conditions for single form based on its id */ if ( $formId == 1 ) { } /* END of conditions for single form based on its id */ /* Conditions for forms based on the presence of a CondXXX.js file where XXX = form id */ $hookName = 'Cond' . $formId; $condFile = $myBaseURL . $hookName . '.js'; if (file_exists($condFile)) { wp_enqueue_script($hookName, $condFile, array('jquery')); } /* END of conditions for forms based on the presence of a CondXXX.js file where XXX = form id */ } add_action('wp_enqueue_scripts', 'wpcf7_loadConditions');But I only get a “Fatal error: Call to a member function id() on a non-object” for the line
$formId = $wpcf7_data->id();Any idea or help, anybody?
Forum: Plugins
In reply to: [Contact Form 7] Checkboxes, pipes not working for multiple recipientsTo check php errors:
In config.php, add
define('WP_DEBUG', true);anddefine('WP_DEBUG_LOG', true);You will find a file
debug.logintowp-contentdirectory.Forum: Plugins
In reply to: [Contact Form 7] Easy calculation in Conact Form 7You can do it with jQuery.
You have to bind a change function both to [number A] and [number B]; the function will set the value of [number Total] to A*10+B*15.
This will only work with javascript enabled browsers.
Forum: Plugins
In reply to: [Contact Form 7] Decimal digits increment for spinbox and range controlOk… In the meanhile, I answered myself it was a stupid question: I just shifted from centimeters to millimeters to automatically solve the problem.
Forum: Plugins
In reply to: [Contact Form 7] Dynamic Dropdown SelectionSorry if I ask a stupid question: does it work with permalinks enabled?
Forum: Plugins
In reply to: [Contact Form 7] Decimal digits increment for spinbox and range controlInspecting the html output, I noticed that if the step is set to a decimal number (e.g. 0.1), the attribute
stepof the field does not appear at all.I presume the plugin does not accept decimal spinbox controlled input.
Is there a way to make it work? Any help or simply an answer is very welcome.
You are very welcome 🙂
Forum: Plugins
In reply to: [Contact Form 7] Dynamic Dropdown SelectionHello, there.
I’m interested in the “GETTING DEFAULT VALUES FROM THE CONTEXT” topic; where can I find it?I noticed a typo:
- Standard products will let users select a product code to which correspond pre-set shape, width and height, and then let the user input only the desired lenght.
- Custom products will have users define shape, width, height and lenght.
In addiction to that, I want to specify this is a solution also to my answered question that you find here.
For the solution, see my post here.
Forum: Plugins
In reply to: [Contact Form 7] Any plans of added calculation to ContactForm7?Hello there.
You can do any calculation easily with jquery, and manage the result (hidden or not) via CF7. I’m sorry I couldn’t understand exactly the calculation you need.
I understood you want your users to input the number of rooms to be painted.
Then you want to multiply the single room cost (300£) times the number of rooms to be painted. That’s clear. But what now? You can do calculations via query and CF7 can hold the result in a field. Then it can send an email to you, or you can use the post data to do something else (i.e. passing them to an e-commerce application or whatever).I did not understand what you do want CF7 to do with the calculated data.
Can you please clarify?