Jump to content

php/javascript dynamic textareas


rajchahal

Recommended Posts

hi

Background

I'm creating an admin control panel.

I have a whats on section that stores multiple dates for events, table 1 holds event info, name, location etc

The 2nd table holds occurances of events, these are date pairs, publish-date and unpublish-date.

 

On the admin page I would need to to insert items into table 1 and items into table2, but with table 2 I may have more than one occurance (record) to add. As I could have 1 or more sets of dates an event occurs on.

 

I need only ONE button that would update both tables.

 

Also, to make this a bit user friendly, with table 2 I would like to have a + / - buttons So I can either add another date pair or remove a date pair. So I'm assuming I need to use javacript to do this.

 

The idea is to read table 2, put these occurances in a javascript array which also populates the required textfields, add some sorto of mechanism that can delete the textfield and update the array without refresh of page, once the submitted javascript transferes variables back to php and table1 and 2 are updated.

 

I was hoping someone can help me with this.  Appreciated

Thanks

   

 

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • 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.