Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

HTML forms are used to pass data to a server. An HTML form can contain input elements like text fields, checkboxes, radio-buttons, submit buttons and more. A form can also contain select lists, textarea, fieldset, legend, and label elements.

2
votes
1answer
30 views

How to call WordPress functions from a form processing script

I'm working on a plugin which submits data via a form from a custom admin page. This is a simplified version of my form: <form action="<?php echo plugin_dir_path(); ?>/process.php" method="...
0
votes
1answer
14 views

HOw to use images in contact form 7 as selection

Is this possible? I think gravity forms allows that but I cant find the settings in cotant form 7 I would like to put images instead of dropdown menu for example Users would select between three ...
0
votes
3answers
16 views

Issue with contact form 7

A client of mine has installed contact form 7 for their contact forms but they're getting an error in the From field "(configuration error) Invalid mailbox syntax is used." The form looks like this: ...
0
votes
0answers
7 views

limit amount of photos uploaded per cpt post

On my site I have a front end form for users to create a post and upload images. It works fine however I cant seem to figure out how to limit the number of images per post. The image attachments get ...
0
votes
1answer
48 views
+100

Customize reset password form redirect problem

I would like to create my own reset password form and page, I mean this page: I have already created a page template for the reset password form, the code: <?php /* * Template Name: Page - Reset ...
1
vote
1answer
9 views

How to handle a custom form in wordpress to submit to another page?

I know in PHP I can just put action equal to random.php file and process the data there, but how in wordpress can I use already existing page with a custom template to submit a form to, so that after ...
0
votes
0answers
17 views

Where to put a custom user login / register form?

i'm currently developing a website that needs the users to register / login, etc. Almost all the web functionalities are working well and as intended, BUT the login / register form not; let me ...
0
votes
0answers
9 views

WPNewsman Lite: required fields not working as expected

I have created a newsletter subscription form using WPNewsman Lite plugin. There are 2 fields Email and I agree... checkbox. They are both marked as required but users can click the submit button or ...
0
votes
0answers
13 views

Ultimate Member Form Submission Help [closed]

I am actually really at a loss with WordPress. I know that I might be able to figure this out if I learn WordPress from the ground up but I was thrown this simple task and would just like to know how ...
0
votes
1answer
25 views

Changing input type from text to multi select dropdown - skill taxonomy

Really need help with a wordpress code please. I have a field on a form which adds tags to the post. Problem is, its free for anyone to enter anything. This keep populating the "skill" taxonomy. The ...
0
votes
0answers
15 views

Wordress Front-end post category array

I have been trying to build a front-end form to wordpress post. I am using a custom post type but not a custom taxonomy, and these works fine. I am doing this with the wp_insert_post function, trying ...
0
votes
2answers
23 views

How to submit custom form data using ajax to HubSpot form?

I am new in WordPress. I have created a custom form in WordPress. When clicking on the submit button I want to submit form data using ajax to HubSpot. Please, anyone, help me how to complete this ...
0
votes
0answers
22 views

How to prevent urlencoded querystrings in custom search forms

When searching using WordPress's default site search, URLs appear with pluses for spaces and punctuation is maintained. For example searching for foo bar, foo bar using: <form action=""> <...
0
votes
1answer
21 views

CRUD front end for mySQL in Wordpress

I hope I've come to the right place. I want to enrich my Wordpress site with a front end to MySQL database, which I host on the same server as my WP site. I have actually migrated my (former) MS ...
0
votes
0answers
20 views

global variable in form

I just created a WordPress plugin with a custom form In my plugin (myplugin.php): function form_search() { if (isset($_POST['send-search']) && isset($_POST['search-verif'])) { if (...
0
votes
0answers
11 views

Page form submit fail

I have created custom form with bootstrap in wordpress page and it does not validate nor send email, no any effect after i press submit button. Before i created same form with same php validation ...
0
votes
3answers
66 views

Ajax call to php function doesn't work PHP code

I have a form like this: <form method="post" action="" id="BookingForm"> <label for="email">Email</label> <input type="text" name="email" id="emailId" value="" /> &...
0
votes
0answers
25 views

Transmit failed! Error send message!

There is a problem with the form I'm using in my wordpress theme,when I hit the submit button this error shows: "Transmit failed! Error send message!" I'm not using Contact Form 7!! This is the form ...
0
votes
0answers
26 views

Building a logged-in user form that interacts with database

I am building a data-entry form for a wordpress website, strictly for logged-in users with editing capabilities. Conceptually, the user selects a database table from a list. The website generates a ...
0
votes
0answers
10 views

How can I save the checkbox values on all wordpress pages for the current user?

How can I save the checkbox values on all pages for the current user? For all other users, the code does not apply. I have this code: <form method="POST"> Option One: <input type="...
1
vote
0answers
13 views

php form create 2 posts

somebody tried to create a plugin to display a form on the front, wich can add post . To fill it, user must create an account or login. When he create his account, he have to fill 2 field only for the ...
0
votes
0answers
17 views

how do i add a subscription form to all my blog posts using the landing.php Template in oceamWp?

I am using a sendinblue plugin for my subscription forms. I have a short_code and I want it on top of all my Blog posts. I tried to add it to the landing.php page like bellow <div id="content" ...
0
votes
0answers
22 views

wp_signon works localhost but not wokrs https site

I made my own login form with using wp_signon but i have a problem. It logins perfect in my localhost but not works on my real https web site. Here is my code. $args = array(); $args[ 'user_login' ]...
0
votes
1answer
35 views

How to change form action of wp-login page with a function

I'm manually creating my own Wordpress login form. The action parameter of all the forms points to wp-login.php. I want to change it for all of them to custom url (/login). Any idea how to that? For ...
0
votes
0answers
29 views

Error handling for wpdb error - displaying an error message to the user

I want to display an error message to a user when a php POST form fails. The form lets a user create a new team on my site. If the team name is not unique, the query fails. I want to display a generic ...
0
votes
1answer
333 views

How to disable autocomplete for inputs in contact form 7?

I have below code for contact form 7. Usually I use autocomplete="off" for html input field. However not able to figure out how to do the same for contact form 7 <div class="row"> <div ...
2
votes
2answers
32 views

Change register form action url

I have 2 registration forms, default one on /wp-login.php?action=register for "recruiter" users, other one on /wp-login.php?action=register&type=candidat for "candidates" users My problem is that ...
0
votes
1answer
12 views

How can I change my search form to bring up product results, not blog results

I'm currently building a wordpress/woocommerce site using a template, and am having issues with the search form & results. When using the search bar, results come up with the title 'blog', and ...
1
vote
2answers
144 views

Prevent page reload after ajax form submission

I'm trying to submit a form in wordpress with ajax. But after the first submision the page itself is called again. My Form <form class="et_pb_contact_form clearfix" method="post" action="" id="...
0
votes
0answers
9 views

Add two fields to woocommerce product frontend

I've been following this tutorial: https://www.kathyisawesome.com/add-a-custom-field-to-woocommerce-product/ on how to add a custom field to the front end, that saves to the order and is stored in a ...
0
votes
0answers
65 views

WooCommerce - updating address fields in registration form

I've added some WooCommerce checkout form fields to the registration form, since my site requires customer to provide their billing address during registration. // Custom function to display the ...
0
votes
1answer
17 views

custom search query database in child theme

I am trying to display searched data from database in wordpress child theme. It does work on localhost but when I apply the code in wordpress only Warning: Invalid argument supplied for foreach() ...
0
votes
0answers
17 views

Adding a different domain to existing Wordpress site

I haven't really found a question covering this topic and I'm sure that's because I don't know exactly how to word it. The problem is the following: My boss has recently overtaken the Swiss branch of ...
0
votes
0answers
18 views

Show ajax form resuslts in page

I have this multi-steps form which should filter through user's choices and give back a list of posts, related to that choices. I'm trying to do that with ajax, but even if I get the response in ajax ...
-1
votes
1answer
21 views

Can't edit Contact Us form on front page

I can edit everything on the homepage except the Contact Us form. It is not a gravity form listed in our list of forms, and it is not a contact form 7 plug in. It is not a sidebar. I cannot get to it ...
0
votes
0answers
10 views

Wordpress Filters with conditions

I want to make an online shop with wordpress - woocommerce. How to create a search formular with following conditions: chose a car-make (audi, mercedes) chose a car-model(if audi selected show A1, ...
0
votes
1answer
19 views

.html form added to a page

I have an external html form that I would like to add to my wordpress developed site. The form links to other areas in the business like the cashiers, so when customers fill the form out, the ...
0
votes
0answers
18 views

Allowing upload of files without an extension based on MIME type

I am trying to allow the upload of files that match a specific mime type, regardless of what the extension is (and even if there is no extension at all.) Currently, wordpress is blocking these ...
0
votes
0answers
8 views

Proper way of creating custom admin form page without WP taxonomies

I'm migrating an app from another CMS to WP. As it already has a lot of data (complex db structure), I'll be using custom SQL queries and just use the existing SQL table structure. If I understand it ...
0
votes
0answers
18 views

How to save data input by client while filling out the form?

I have a small website with 2 different contact forms. One form, created using Caldera forms (drag-and-drop) is quite long, about 10 pages (can't make shorter), and i was curious if there is a way to ...
1
vote
0answers
47 views

Create form on plugin options page that creates submenu pages for that plugin

I've created a plugin that adds an admin menu section that is visible to clients (Client Section) when they login and another that is only available to our staff (Staff Section). Our staff needs to ...
2
votes
0answers
68 views

Linking three taxonomies with ACF

I'm creating a product finder using a CPT called "Products", which is already used for displaying products separately on the site. The product finder is based on a answer and question idea, where the ...
-1
votes
1answer
38 views

Send foreach $_post method to contact form 7 [closed]

I have a list of products generated by Javascript, I need to send them by the POST method via “contact form 7” If the list had 10 items, it would not be too heavy write 10 lines of code with "Contact ...
0
votes
0answers
11 views

I want to create multi-page products that can be choosed with radio button. Then user clicks next and the info is sent to me. How?

Basically I want to create a shop that has a progress bar. Each step has multiple products that the user can choose. Then after clicking next the user is sent to the next step of products. All that ...
1
vote
3answers
58 views

How to submit data from HTML form?

I built a custom HTML price calculator with a form that when gets submitted calls a PHP file through the action attribute and this PHP file then sends the collected data to my company's email and ...
0
votes
1answer
66 views

Output multi-steps form results in same page

I'm trying to make a multi-step forms with radio buttons, which will be used to filter some custom posts. Here you can see an example. Right now, once the user complete and submit the form, the page ...
0
votes
1answer
204 views

Auto Submit Contact Form 7

I’m looking for solution whole day but can’t find anything that work. So I want to automaticaly submit CF7 on page load. If I use any jQuery or JS solution there is some endless looping on the site. ...
0
votes
0answers
34 views

Form validation and error message display

I have a custom HTML form on a page. I'd like to do some server-side validation. If the validation is successful, I'll process the request and wp_redirect to another page. If the validation fails, I ...
0
votes
1answer
23 views

textarea field is getting escaped for some unknown reason

It doesn't happen outside of WordPress, so I'm posting here. I'm using a textarea field in a custom form, and before I have a chance to do anything with it, I find it's escaped: echo $_POST['...
0
votes
0answers
200 views

Using PHPmailer to send to multiple recipients' email addresses contained in variables?

I'm trying to send a form submitted email to two recipients, both emails are contained in variables. I've tried the code below and it doesn't send out at all. I tested the variables with echo they ...