Well as far as I was able to work out your problem you are having difficulties posting the information. If that is te case i see a few problems:
1.you are missing form opening and closing tag(in your case you need one before the while loop and one after it) which will take the user input somewhere.
2.this is a dynamic form meaning that you might add new inputs in the database at any gievn time. Which means that your inserting method will skip the new once if it's a single "insert into sometable" query. So what you could do is store each input in a separate row. your option is to organize your database like
id, user_id, some_stock_id_or_whatever, input
then assuming it wont be 5000 inputs each time you could do something like
thats just a quick reply really so you might need to fix it up a bit but that should give you a headstart... if that's of course what you are trying to achieve....