.val(value) documentation should discuss checkboxes more accurately

Aperta
#991 1 commento 0 reazioni 1 assegnatario Vedi su GitHub

@AurelioDeRosa ci sta già lavorando.

Dal 19/12/2016.

Valutazione

Questa issue non è ancora stata valutata.

Descrizione

I created the following issue on the jQuery forums:

http://forum.jquery.com/topic/val-value-does-not-work-on-checkboxes-if-value-is-not-an-array

I like the alternative method brought up by Jake, as it seems more clean. The way that jQuery works does make sense; however, the documentation is misleading. It doesn't state that the use of an Array is required, rather it states that you can use Arrays. I would add a note related to Jakes alternate method for checkboxes, as a better way of working with checkboxes.

Take it easy,
Will

Lingua principale
HTML
Stelle
324
Fork
259
Merge medio
1g 30m
PR unite (30g)
1

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di jquery/api.jquery.com

Tutte le issue di jquery/api.jquery.com

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.