.SPServices.SPCascadeDropdowns: mulitple selections?

Apr 7, 2010 at 10:46 PM

Is it possible to have multiple selections for a child drop down? 

Also, when i use this code, the dropdowns work as expected, (without the multiple selections of course).

<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery-1.3.2.js"></script>
<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery.SPServices-0.4.5.min.js"></script>
<script language="javascript" type="text/javascript">
	$(document).ready(function() {
		$().SPServices.SPCascadeDropdowns({
			relationshipList: "Regions",
			relationshipListParentColumn: "Country",
			relationshipListChildColumn: "Title",
			parentColumn: "Country",
			childColumn: "Region",
			debug: false
		});
	});

But when I replace the libraries with the newest ones, (in hopes to allow multiple selections on filtered child items), it does not filter the dropdowns?

<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery.SPServices-0.5.3.js"></script>
<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery.SPServices-0.5.3.min.js"></script>
<script language="javascript" type="text/javascript">
	$(document).ready(function() {
		$().SPServices.SPCascadeDropdowns({
			relationshipList: "Regions",
			relationshipListParentColumn: "Country",
			relationshipListChildColumn: "Title",
			parentColumn: "Country",
			childColumn: "Region",
			debug: false
		});
	});

All libraries are in the same source location.  Any thoughts would be greatly appreciated.

Btw, these libraries are amazing.  Thank you so much for writing these!

Coordinator
Apr 7, 2010 at 10:58 PM
Edited Apr 7, 2010 at 10:59 PM

chanley:

The issue is that in the second instance, you're referencing my library twice and the jQuery library not at all!

Can you explain a bit more about what you want to do with "multiple selections"?

M.

Apr 7, 2010 at 11:17 PM

I'm such a fool.  I just changed it and it works perfect.

<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery-1.3.2.js"></script>
<script language="javascript" type="text/javascript" src="/jquerylibrary/jquery.SPServices-0.5.3.min.js"></script>
<script language="javascript" type="text/javascript">

ultimately, I am hoping to have a parent list of industry "types", (architects, engineers, etc...) as well as corresponding list of "sub-types".

(example; a list item with a "type" engineer may have more than one "sub-type"

The child sub-type list would look something like this:

Type----------------Sub-Type
Engineer              Civil
Engineer              Traffic
Engineer              MEP

I am obviously a bit of a newcomer when it comes to sharepoint development so I truely appreciate your super fast response!

 

Coordinator
Apr 8, 2010 at 2:29 AM

Mistakes like that are what keep me working late at night. ;+)

I would suggest that you upgrade to jQuery 1.4.2, too, which is the latest version. SPServices doesn't require it, but it's got more goodies in it, and I believe it is more efficient.

You can have multiple "cascades" on your page.  Just add them in sequence.

M.