Tagged: CONTACT FORM, request a quote
-
AuthorPosts
-
May 15, 2023 at 3:13 pm #1407445
Hi,
I have a website with more products and, for each one, I have a “request a quote”, but i don’t’ know how to receive automatically the page of the request…Can you help me please?
Looking forward hearing from you.
Best regards
MSMay 16, 2023 at 5:51 am #1407508Hi MS,
Are you using a plugin for “Request a quote”? like https://wordpress.org/plugins/yith-woocommerce-request-a-quote/
Best regards,
NikkoMay 16, 2023 at 11:11 am #1407545Hi, Nikko,
no I use the contact form provided from theme…
Best regards,
MSMay 16, 2023 at 11:47 am #1407562Hi MS,
I see, you can add this PHP code in your child theme’s function.php:
add_filter('avf_form_subject','avia_change_mail_subject', 10, 3); function avia_change_mail_subject($subject, $new_post, $form_params) { $subject = $subject . ' - ' . $_SERVER['HTTP_REFERER']; return $subject; }This will add the URL where the form was submitted and added after the subject.
If you aren’t using a child theme yet, then you can download it here: https://kriesi.at/documentation/enfold/child-theme/
And follow the instructions under Install a child theme from your WordPress dashboard.Hope this helps.
Best regards,
NikkoMay 16, 2023 at 6:03 pm #1407650Done!
Thanks you!May 16, 2023 at 6:08 pm #1407651Hi, It will be great if the link will be in the body of message.
Is possible?May 17, 2023 at 5:13 am #1407695Hi maryenvato,
Yes, it’s possible, use this PHP code instead:
add_filter('avf_contact_form_incoming_mail', 'avia_append_url', 10, 6); function avia_append_url($mail_array, $new_post, $form_params, $class, $from, $from_filtered) { $referrer = "\r\n URL: " . $_SERVER['HTTP_REFERER'] . "\r\n"; $mail_array["Message"] .= $referrer; return $mail_array; }Best regards,
NikkoMay 17, 2023 at 8:39 am #1407710Perfect!
Thanks you!May 17, 2023 at 9:28 am #1407715Hi maryenvato,
We’re glad that we could help you :)
Thanks for using Enfold and have a great day!Best regards,
Nikko -
AuthorPosts
- The topic ‘Contact form with “page”’ is closed to new replies.
