Choices-js / Choices

A vanilla JS customisable select box/text input plugin ⚡️
https://choices-js.github.io/Choices/
MIT License
6.06k stars 597 forks source link

POST multiple instances not working #1063

Closed MarkFirman closed 1 year ago

MarkFirman commented 1 year ago

Describe the bug When trying to POST two instances of the multi select choices via PHP; the second instance of the choices box is never sent via the POST request.

To Reproduce

  1. Create two instances of a multi select choices box; each having a unique name wrapped in a HTML form that POSTs to a PHP script.
  2. Run: print_r($_POST) on the PHP script to output a list of all posted objects and note the second instance of the choices select box does not exist in the POST request

Expected behavior Both results are posted through to PHP

Screenshots Notice two instances of the choices box is enabled, each with a unique name (articletags[] and linkedarticles[]) image

Notice how when checking the POST request, only 1 of the choices boxes was pushed through (the first one) image

Desktop

MarkFirman commented 1 year ago

Turns out this was an issue with my web server, and not the plugin.