dropdown list dependent on previous selection

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
mzenns
Posts: 11
Joined: 23 Jan 2009, 20:03
Location: N. Central PA

dropdown list dependent on previous selection

Post by mzenns »

We have multiple locations in several states where users can report issues. Due to the nature of the reported issues, it's important many times to know where the issue has occurred. I'd like to create 2 dropdown fields, the first containing the names of the States where we have locations, and the second that would show the locations within that State. Therefore, the available choices in the second dropdown would change, depending on the selection made in the first dropdown. Is this possible, and if so, how would I accomplish it?
Mike Zenns
Mantis Administrator
v. 1.0.8
Ubuntu 8.04 server
cas
Posts: 1768
Joined: 11 Mar 2006, 16:08
Contact:

Re: dropdown list dependent on previous selection

Post by cas »

Check this out:
http://www.huanix.com/2006/12/25/dynami ... avascript/

Always check your friend first, that is what i did: google
mzenns
Posts: 11
Joined: 23 Jan 2009, 20:03
Location: N. Central PA

Re: dropdown list dependent on previous selection

Post by mzenns »

That looks like exactly what I need. Any idea which file to add the code to? I'm running v1.0.8.
Mike Zenns
Mantis Administrator
v. 1.0.8
Ubuntu 8.04 server
cas
Posts: 1768
Joined: 11 Mar 2006, 16:08
Contact:

Re: dropdown list dependent on previous selection

Post by cas »

mzenns wrote:That looks like exactly what I need. Any idea which file to add the code to? I'm running v1.0.8.
First of all, upgrade to the latest version which allows for plugins.
If you want top stick to current version, look at bug_report & bug_update scripts.
You may be able to accomodate this with a plugin in combination with additional fields. Do not think custom fields is a solution here.
Post Reply