Get Array Input Value Javascript Substring Function In C