Jump to content

Multiple TextBox AJAX


billy_111

Recommended Posts

Hi,

 

Is there a way i could have a text input box and when a user types something inside and clicks off it, a new textbox appears just underneath? It doesn't just have to appear, it may be good to have a link saying "add new..." and then on clicking this it show s anew text box.

 

But firstly is this possible? I want to apply it to this:

 

http://www.prima.cse.salford.ac.uk:8080/~ibrarhussain/patent.jpg

 

Just underneath the "file upload" box. I want to insert the values of each textbox into a database, there will be no limit as to how many textboxes appear..

 

Can anyone help?

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/208996-multiple-textbox-ajax/
Share on other sites

I have tried getting something working with jQuery but what is happening it adds the wrong text box:

 

http://www.prima.cse.salford.ac.uk:8080/~ibrarhussain/test.html

 

If you click on "Add author" it adds the "Title" text box instead of adding the "Author" text box.. Any ideas how i can fix this?

 

Will this method be practical when i want to add/update the values in the database?

 

Thanks

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.