A
A
Alexander Bagirov2015-01-21 19:35:39
PHP
Alexander Bagirov, 2015-01-21 19:35:39

How to get data from dropdown in PHP?

Good evening.
I have a form that has a couple of input fields and one dropdown. after submitting, everything is passed to PHP. How can I get the value of the selected option in the dropdown?
Please show an example.
Thank you.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Aksentiev, 2015-01-21
@alexbagirov

var_dump($_POST); to help you in the
same way as the rest of the fields, only if it's not some kind of CSS dropdown instead of select
If css then save the selected using JS in a hidden field when changing

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question