passing dynamic id's to javascript

后端 未结 2 1901
离开以前
离开以前 2021-01-16 11:17

i have a while loop that changes the id of each input field.

   print\"

        
2条回答
  •  耶瑟儿~
    2021-01-16 11:34

    form.pro0.value;

    is used to access input with name as pro0

    Try form.productitemsupdate_0.value or

    try using getElementById http://www.tizag.com/javascriptT/javascript-getelementbyid.php

    Also change your php code to

    print"}";
    

提交回复
热议问题