Populate custom publish forms with javascript

I have a custom publish form I've put together in the control panel which is being used to manage content from a database. I've built a couple different forms already, and things are working as desired for the most part.

I'm having an issue with one form in particular, which lives in a modal. The user clicks on one of many links on the page, which spawns a modal (using jquery). I've done this on the frontend with no issues, but in the control panel using the custom publish forms, I'm having a but more trouble. I want the form to populate the hidden id field with a value based on whichever link was clicked, and clear all fields when it's cancelled.

Using the custom publish forms, there doesn't seem to be an option to set the id or class of an input field, which is how you attach a javascript command to it. Am I missing something, or is there a better way?


>>>>>>> Unanswered <<<<<<<
0 Replies
1 Follower