Added support for multiple inputs with the same name