vader7071
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Problem after update WordPress 6.1I am having the same issue. Upgraded web host using MultiPHP Manager from PHP 7.2 to 8.1. Now I am getting these and other errors.
Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 7022 Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 2162 Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 7022 Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 2162 Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 7022 Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 2162 Deprecated: strpos(): Passing null to parameter #1 ($haystack) of type string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 7022 Deprecated: str_replace(): Passing null to parameter #3 ($subject) of type array|string is deprecated in /home/{site host}/wp/wp-includes/functions.php on line 2162 Warning: Cannot modify header information - headers already sent by (output started at /home/{site host}/wp/wp-includes/functions.php:7022) in /home/{site host}/wp/wp-admin/includes/misc.php on line 1416 Warning: Cannot modify header information - headers already sent by (output started at /home/{site host}/wp/wp-includes/functions.php:7022) in /home/{site host}/wp/wp-includes/functions.php on line 6865 Warning: Cannot modify header information - headers already sent by (output started at /home/{site host}/wp/wp-includes/functions.php:7022) in /home/{site host}/wp/wp-admin/admin-header.php on line 9
Forum: Plugins
In reply to: [My Custom Functions] Help with fatal error – parse errorForum: Plugins
In reply to: [My Custom Functions] Help with fatal error – parse errorI really need help with this. A function of my site is down until I can get this corrected.
Forum: Plugins
In reply to: [Contact Form 7 Multi-Step Forms] Data not passing from each stageI did have an error in my multistep line on page 1 and I corrected it.
I did not realize I needed a multistep line on page 2 as well. I added the line as above and that solved the issue. Thank you.
Forum: Plugins
In reply to: [Contact Form 7 Multi-Step Forms] Data not passing from each stageI stopped the form at step 2 to make sure the information from step 1 was being transferred to step 2.
Looking at the setup now, just look at it like a 2 step form.
From step 1 to step 2, I lose all of the data from step 1, but step 2 comes through.
Here is the email I received when I tested it:
{step 1 – attempted both field setup, no data sent}
[first-name]
[middle-name]
[last-name]
[your-email]
[multiform “phone”]
[multiform “addy”]
[multiform “city”]
[multiform “state”]
[multiform “zip”]
[multiform “experience”]
[multiform “education”]{step 2 – just garbage data}
yes
internet
yes
345
3
3dfgdfgsd
dfgdgdf
dgfdfgdfg
dfgddfgForum: Plugins
In reply to: [Contact Form 7] Setting radio button options verticalOk, I just checked the link to make sure it worked.
Now the options are showing like I want them. Must have been a gremlin. Thank you.
Forum: Plugins
In reply to: [Contact Form 7] Setting radio button options verticalhttps://ceceinc.com/application-page-3
This is page 4 of a multi-stage form. I am still currently testing other aspects so it is not live, but it will display what I am needing help with.
- This reply was modified 5 years, 3 months ago by vader7071.
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?No, your code was perfect. It did exactly what I wanted. I just put it into the function file wrong. And using the custom function plugin made it easy.
As for the paypal plugin, the author has hard coded the free version to only accept numbers unless you upgrade to the pro. So there was no way for you to get it to work, and I wouldn’t want to try and override his work.
I’m talking with the owner about what they want to do now, but just this addition will make them very happy!
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?Thank you for all of your help!
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?Update on the paypal addin. I think I found out why. I have to go pro to be able to link tags to paypal. So that is not an issue with CF7, that is between me and the plugin.
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?As is with a good programmer, I tested further.
I loaded the “Custom Functions” plugin you suggested. That fixed the mail part. Apparently I did something wrong in functions.php. But this works, so I am happy.
The data did come through as it was supposed to. So when I set my values to (1) $20 spot, and (1) $40 spot and yes to power, I got 80 out.
Now, I did go to the Paypal tab and tried to update that. Under that tab it has a spot for “item price”. In that I put in [sum], just like in my mail tab. When I saved it, it takes out the [sum] and replaces it with 0.00.
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?[double by accident]
- This reply was modified 6 years, 9 months ago by vader7071.
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?Awesome! thank you!
I made the changes (fixing power to “yes|1” “no|0” and adding the hidden field).
I can follow the code and it makes sense. I added the code, as shown, to the bottom of my functions.php file in my theme.
I ran a test message. The webpage is:
https://wiregrasshighlandgames.com/wp/clans-contactWhen I filled out the form, clicked submit, it went to:
https://wiregrasshighlandgames.com/wp/clans-contact/#wpcf7-f490-p495-o1with nothing on the screen. I also have not gotten the email. Paypal is not turned on yet, I wanted to make sure the data was sent through first.
To make sure, here is my form:
<label> Clan Name (required) [text* your-clan] </label> <label> Clan Contact (required) [text* your-name] </label> <label> Contact Email (required) [email* your-email] </label> <label> Contact Phone Number (required) [tel* your-phone placeholder "xxx-xxx-xxxx"] </label> <label> Mailing Address (required) [text* mailing] </label> <label> City, State, Zip (required) [text* csz placeholder "city, state zip"] </label> <label> Website [url your-website] </label> <label> How many spots 15x15 (Clan supplied tent) $20/ea [number* tents min:1 max:5 placeholder "0"] </label> <label> How many spots 15x15 (SEAHG supplied tent) $40/ea [number* seahg-tents min:0 max:1 placeholder "0"] </label> Will you need power? $20 [checkbox* power use_label_element exclusive "yes|1" "no|0"] <label> Comments [textarea your-message] </label> <label> <a href="/terms-conditions">Terms & Conditions</a> [acceptance terms] <a href="/terms-conditions">I accept the <u>terms and conditions</u></a></label> <input type="hidden" name="sum" /> [submit "Send"]
Here is my Mail:
From: [your-name] <[your-email]> Subject: Clan Application Message Body: Business Name: [your-clan] Business Contact: [your-name] Email: [your-email] Phone: [your-phone] Mailing address: [mailing] City, State, Zip: [csz] Website: [your-website] How many spots? [tents] How many tents? [seahg-tents] Will need power? [power] Comments: [your-message] Registration fee: [sum] -- This e-mail was sent from a contact form on Southeast Alabama Highland Games
And this is what I added to functions.php:
// Added for Contact Form 7 to link Registration form to Paypal // Clan Application add_filter( 'wpcf7_posted_data', function ( $data ) { // Set this to the form ID. $form_id = 490; /* * This is necessary, which ensures that we are filtering/modifying only * the data submitted via the form with the ID of $form_id and not all forms! */ $form = wpcf7_get_current_contact_form(); if ( ! $form || $form_id != $form->id() ) { return $data; } // [sum] = {([tents]*20) + ([seahg-tents]*40) + ([power]*20)} $data['sum'] = $data['tents']*20 + $data['seahg-tents']*40 + $data['power']*20; return $data; } );
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?Oh terrific. Thank you!!
Here is the exact CF7 code I am using:
[contact-form-7 id="490" title="Clan Contact Form"]
<label> How many spots 15x15 (Clan supplied tent) $20/ea [number* tents min:1 max:5 placeholder "0"] </label> <label> How many spots 15x15 (SEAHG supplied tent) $40/ea [number* seahg-tents min:0 max:1 placeholder "0"] </label> Will you need power? $20 [checkbox* power use_label_element exclusive "yes" "no"]
So the “math” will be:
[sum] = {([tents]*20) + ([seahg-tents]*40) + ([power]*20)}
Basically I will need [power] not to be a T/F or a Y/N, but treated as a 1/0.
And then once this is run, I’d like [sum] to be accessible by the Paypal addon feature.
Basically the idea is a person is registering, they select what they want/need, and then when they hit submit, they can pay via paypal.
Forum: Plugins
In reply to: [Contact Form 7] Can Contact Form 7 do simple math?Thank you. Searching I found this: https://contactform7.com/dom-events/, but I can’t find one that triggers just before send.
Do you know of a tutorial where I can read up on how to add the function?